I've had a ton of help recently from the SO community and I'd first just like to say thank you to everyone!
My latest Google Sheet pursuit is querying sec.gov for the latest filing for a given ticker. I'm not trying to scrape the site, I just want to pull in the latest filing so I can alert myself as to when a company has filed something new with the SEC.
I'm currently doing this for each ticker by way of importhtml and index:
index(
importhtml("https://www.sec.gov/cgi-bin/browse-edgar?action=getcompany&CIK="&A2&"&owner=include&count=100",
"table",3),2)
... where the ticker is in cell A2. However this has been working inconsistently because I'm continually trying to do this for over 2500 tickers. I've noticed that importhtml runs into issues when there are so many calls at once.
Is there some way to automate this via Google Scripts so that I can call in the latest filing (or latest 5 filings or so) on a nightly basis? I'm plenty familiar with Google Scripts and triggers I just don't know how to get around that importhtml limitation, and how to limit my script to only the latest ~5 filings so as to not overwhelm my spreadsheet. Just need a gentle nudge in the right direction.
Thank you!