Why is Smartsheet only adding one blank row instead of all the rows it read from G-sheet?
Hi, I'm trying to make a script from Apps Script to work with Smartsheet and I'm stuck.
The script is to process some rows that need to be copied to a specific Smartsheet based on some filtering criteria, but after the script runs, we can see the following.
Is there anything that might be preventing Smartsheet from pasting the values as expected?
- Headers Found: The headers from the Google Sheet are correctly read and logged.
- Data Read: The data from the Google Sheet is read correctly and logged.
- Filtering: Rows are filtered based on the batch number, and the filtered rows are logged to confirm that the filter is working as intended.
- Mapping: Each row's data is mapped to the corresponding Smartsheet column IDs, and the mapping is logged for each header. The logs indicate that the mapping process is working correctly for each row.
- Payload Creation: The full payload being sent to Smartsheet is logged and appears to be structured correctly, with an array of rows, each containing an array of cells with column IDs and values.
- API Response: The response from the Smartsheet API is logged, showing a response code of 200, which means the request was successful. The response body indicates "SUCCESS" with no errors reported.
- Parsed Response: The response body is parsed and logged, confirming the successful addition of rows.
I'm attaching the script here with the sensitive information ommited.
Thanks!
Answers
-
It doesn't seem like the members of the Smartsheet Community are familiar with Apps Script to be able to help troubleshoot this with you. At this point I would suggest reaching out to the Apps Script Community or their Support team to dig into the script with you.
Need more help? 👀 | Help and Learning Center
こんにちは (Konnichiwa), Hallo, Hola, Bonjour, Olá, Ciao! 👋 | Global Discussions
Categories
- All Categories
- 14 Welcome to the Community
- Smartsheet Customer Resources
- 64.1K Get Help
- 414 Global Discussions
- 221 Industry Talk
- 461 Announcements
- 4.8K Ideas & Feature Requests
- 143 Brandfolder
- 141 Just for fun
- 58 Community Job Board
- 462 Show & Tell
- 32 Member Spotlight
- 1 SmartStories
- 299 Events
- 38 Webinars
- 7.3K Forum Archives