Forum Discussion
how to create a query that paginates?
- 10 years ago
With List.Generate you should be able to "harvest" the list of URL's - you can even try to "harvest" the content at the same time. (But watch out: There's an error in the documentation: Result of last example should be {2, 4, 6, 8})
See Chris' article on how List.Generate works in general: http://blog.crossjoin.co.uk/2014/06/25/using-list-generate-to-make-multiple-replacements-of-words-in-text-in-power-query/
ImkeF I try to cut the URL but I keep getting an error, please help.
= let
Source = Xml.Tables(Web.Contents("https://api.dovico.com/TimeEntries",
[RelativePath="/?daterange=2020-01-01%202025-12-31&version=5"],
[Headers=[#"Authorization"="WRAP access_token=""client="&DovicoAccessToken&"&user_token="&DovicoUserToken&""""]])),
Data0 = Source{0}[Data]
in
Source
Hi Anonymous ,
the Web.Contents function takes max. 2 arguments. So you must combine everything after the URL into one record:
= let
Source = Xml.Tables(Web.Contents("https://api.dovico.com/TimeEntries",
[RelativePath="/?daterange=2020-01-01%202025-12-31&version=5",
[Headers=[#"Authorization"="WRAP access_token=""client="&DovicoAccessToken&"&user_token="&DovicoUserToken&""""]]])),
Data0 = Source{0}[Data]
in
Source