Forum Discussion
nikolai_nopost
3 years agoNew Member
Power Query request data every 5 minutes even I set timeout 30 minutes
Hello, I have a query that requests data from external API I know that it takes a lot of time to get the answer so I set a timeout 30 minutes = Json.Document(Web.Contents("url",[Timeout=#duration(...
BA_Pete
3 years agoSuper User
Hi nikolai_nopost ,
The timeout argument doesn't stop the query trying for that amount of time, it tells it when to give up. It may make many attempts during that time but, after 30 mins, it will return a fail.
I think what you want to use is Function.InvokeAfter(), where you can actually limit the calls via a specified time delay.
Check out Chris Webb's blog here:
https://blog.crossjoin.co.uk/2015/04/30/using-function-invokeafter-in-power-query/
You'll obviously need to correctly integrate it within your current query, but I think this is the function you need.
Pete