When you create many rows at once in Coda (or lately, even one or two), their Row IDs are not assigned immediately but after some time. I assume that this happens because Coda needs to store the row on the backend first. It also applies some rate limiting, that’s why if you create lots of rows, their Row IDs will only appear one after one with some delay. You can observe this behavior by clicking the
Create 20 rows button and looking at the Data table.
Sometimes though you need to perform some actions after creating those rows, and you want to be sure that all Row IDs are in place.
The solution is to set up the loop like I explained here that will run until there are no rows with empty Row ID. To optimize the loop, it may be a good idea to set up
millis somehow dependent on the number of remaining rows, e.g.
Remaining rows count * 250.
Demo (you may want to clone the doc, otherwise rows are never saved and Row IDs are never assigned):