I have a single Google Sheets file with a set of many-to-many relational sheets linked by association tables. I want to trigger a script when my AppSheet app writes the primary row and all related rows to the sheet.
My initial approach was to trigger the script when a new primary row is added. Iโve since discovered that the order in which AppSheet inserts the ref rows and primary row (or the order in which Apps Script detects those changes) is random/unpredictable, so I have no easy way to know if all related data is present in the sheet before executing my script.
My new approach is to hopefully have the AppSheet app write a โtransaction completedโ row for the main record to a data transaction log sheet, after the main row and all related rows are inserted, and then trigger my script when that transaction log is added. Is this feasible (e.g. can I create an AppSheet event/action triggered when a row and all its ref rows are inserted to the sheet)?
See _ Sending Email Only After Adding a Parent Record and All of Its Children_ here:
User | Count |
---|---|
14 | |
11 | |
9 | |
7 | |
4 |