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.
Join us at Smartsheet ENGAGE 2024 🎉
October 8 - 10, Seattle, WA | Register now
Categories
- All Categories
- 14 Welcome to the Community
- Smartsheet Customer Resources
- 62.8K Get Help
- 376 Global Discussions
- 207 Industry Talk
- 440 Announcements
- 4.5K Ideas & Feature Requests
- 139 Brandfolder
- 129 Just for fun
- 130 Community Job Board
- 449 Show & Tell
- 30 Member Spotlight
- 1 SmartStories
- 284 Events
- 33 Webinars
- 7.3K Forum Archives