Content added dynamically
To check if the content is added dynamically, using Chrome,
Open the URL of the source data.
The IMPORTDATA() function has a latency of approximately 1 hour, as explained in this post on the Google Product Forum.
You mentioned the fact that a script was being fired by a time based Google Apps Script trigger. I was thinking, if you're using a script in the first place, why not fetch the CSV file as well, like so:
var url = 'url to public CSV ...
You are right, the import functions updates their result at certain intervals.
From Change a spreadsheet's locale, time zone, recalculation, and language, a help article from the official documentation,
Note: External data functions recalculate at the following intervals:
ImportRange: 30 minutes
ImportHtml, ImportFeed, ImportData,...
(maybe not the answer, but here is a quick humble scraping guide)
the first choice is always IMPORTHTML and slowly (1-by-1 row) dragged down
=IMPORTHTML("URL"; "TABLE"; ROW(A1)-1)
if that fails then repeat it with:
=IMPORTHTML("URL"; "LIST"; ROW(A1)-1)
Generating a direct download link, as described in this article seems to work fine with the =IMPORTDATA function.
To summarize, you take the SITE_ID string from the sharing link you have:
Using this, you can generate the direct download link for use with the =IMPORTDATA function:
Across all the sheets you have created. I have run into this same issue before. this includes test sheets youve played with etc. anytime you have added those import functions and not removed them or left them in a state where they will not try to refresh on their own.
You can use Google Apps Script to
Create a menu with an item that runs a script to import your data
The script will not run in Android
Also there is the possibility for Triggers, naming a function in GAS 'onOpen' that actually only runs the function when open.
The code to import data should be 2 or 3 lines, if you are not familiar with GAS take a ...
As best as I can establish, IMPORTDATA won't respect leading zeros in ANY field containing numbers; the field will always be treated by IMPORTDATA as numeric, regardless of sheet formatting. This applies regardless of whether IMPORTDATA is used alone, or in conjunction with other functions such as QUERY.
My proposed solution takes a different approach. ...
The file should be shared to anyone or to anyone with the link
If the file is "small enough" the URL to be used should have the form
If the file is big it could not be imported by using IMPORTDATA as Google Drive big files return a warning
Google Drive direct download for big files