Question

Need help adding multiple rows in Google Sheets

  • 27 February 2024
  • 9 replies
  • 58 views

Hi all, 

I'm setting up an automation to populate a Google Sheet with product data from form submissions, and I'm encountering a challenge with how to best structure data that includes multiple variants like sizes and colours. This is only a small part of a longer zap, but quite a crucial part.

The image below shows Column J and Column L consists of all the size and color variants.

 

The image below shows how the data actually should be structured. 

 

I have tried loads of options that where discussed in this community, like using line items. I do have all the different sizes and colours as separate values, I cannot seem to succeed in placing them right below each other in different cells. 

This is how my zap is currently structured: 

If you need extra data please let me know, as I will provide it asap :)


This post has been closed for comments. Please create a new post if you need help or have a question about this topic.

9 replies

Userlevel 7
Badge +14

Hi @steijnd 

We will need to see screenshots with how your GSheet steps are configured to have more context.

@Troy Tessalone 

 

Here you go: 

 

Is this sufficient?

Userlevel 7
Badge +14

@steijnd 

Data needs to be formatted as an array of item, rather than a string of comma separated items.

 

e.g. Formatter > Utilities > Text to Line Items

 

Help article about handling arrays in Zaps

 

@Troy Tessalone 

 

thanks a lot! At least I have these different size values.
It duplicates al other rows as well. Can this be avoided? If not I guess I just have to deal with it. 
 

I have ran into another problem in this automation, do you mind taking a look at it? 
 

thanks again! 

Userlevel 7
Badge +14

@steijnd 

If you still have issues configuring the Zaps, then we will need to see updated screenshots with how your steps are outlined and configured to give context.

@Troy Tessalone 

This is how the zap is set up, nothing has changed except for the Column “Size” there is now an array of line items. 

 

This is how it sends data to google sheets. Only “Size” should be outputted in multiple rows, the other get duplicated as well. 

 

Thanks!

Userlevel 7
Badge +14

@steijnd 

Ok, then that means the Zap step logic would have to be different.

You would first need to create the row w/o the Size

Then use the returned Row/ID to update the same row with the first Looping iteration for the first Size

Then +1 to the returned Row/ID to update the following rows with the remaining Looping iterations for the Sizes.

Userlevel 7
Badge +14

@steijnd 

For the record, I recommend going with the approach where each row has the full data.

 

@Troy Tessalone 

 

okay thanks a lot! 

I agree with your last comment, but it’s a client’s preference.