I have 4 Queries that use API calls and 3 other Queries that reference these 4 and Merge them with some logic.
Everything worked well till yesterday when I started to get this error: "429 Too Many Requests"
There is a Rate limit of 100 calls per minute but only for the first Query, that should be run only ONCE (see below).
I think that because of Query folding the first Query is actually trigerred many times by all other Queries because they reference it.
Below is the description (unfortunately, I cannot upload the pbix file):
1. Query "Customers"- gets a list of customer ids from API call (https://api.somecrm.com/v1/customers)
2. Query "Purchase History" - References Query 1 and adds an "Invoke Custom Function" column. 3. Query "Customer Tickets" - Similar to Query 2: References Query 1 and adds an "Invoke Custom Function" column.The function gets Customer Tickets history for each customerid (from the first query) using another API call (https://api.somecrm.com/v1/tickets/{customerid})
4. Query "Call Center" - Similar to Query 2: References Query 1 and adds an "Invoke Custom Function" column.
So, the list in Query 1 is the same for all the other 3 Queries.
All 4 Queries are not loaded, but are referenced by 3 other Queries that Merge them with some logic and only the Last Query is loaded into the model.
I feel that each time the custom functions run when referencing the first Query, they trigger it agai and again and again.
1. How can I check it?
2. How can I make sure the first Query is run ONLY ONCE? Even if other queries reference it, I want them to reference the already existing list of customer ids, and not re-run the first query.
3. Mybe Table.Buffer will work? Or some other "staging" mechanism?
Please help