Hello, wishing to load google sheets data into firebase. I’m using a spreadsheet to capture some intermediate data before I transfer to firebase for permanent storage (I could also use local data table, but have challenges troubleshooting in preview mode.
The google sheets data has multiple rows of data so I need to write a “loop” routine to work through each row and load into firebase.
This is my first attempt at the routine (failed after multiple tries).
I’m creating an event (in GameSummaryForms) tagging with a date (YYYYMMDD) and loading game number and game date characteristics.
Then I’m creating a sub-tag group (Incidents) to load all the incident data and assigning a unique incident ID (Event# and Offender), then loading incident time and offender characteristics.
Are you able to set a single cloud variable path (without a loop) successfully as a test?
Have you tried introducing a delay inside the loop? Often, loops that access cloud-based storage need to time to complete. Try a Wait 0.03 seconds block or even a Wait 0 seconds block to see if that helps.
What I’m suggesting is that you need to try to set a value with a sample endpoint from the loop (/Incidents/Event#…) but without using a loop. Just a standalone test to make sure that’s possible. Not just the partial path that you’re trying above the loop. But again, if your paths are definitely correct then a Wait block may be helpful.
I then re-wrote the load routine (2nd part) by removing the loop and attempting to load the first row in the google spreasheet (just grabbed rowID and inserted in the get value blocks). No success. For some reason (I’m still trying to determine), it wasn’t loading to firebase. I’m checking the join structure on the set cloud variable to ensure the tags/subtags are correct. I’m also going to re-program the loading so that I pass one record at a time (instead of multiple records).
Once successful, I will tackle the multiple record loading at one time in the future.
Another insight on my part … Firebase doesn’t allow # characters in the tag/subtag structure. Your program will not load any data to firebase. This was the problem from the start.