Forum Discussion
how to create a query that paginates?
Hi Anonymous ,
I have tried to work with Multi-step function.
Unfortunately I got a problem - Expression.Error: The Name "GenerateByPage" wasn't recognized.
I tried "Table.GenerateByPage", doesn´t work.
let
FetchPages = (url as text, pageSize as number) =>
let
Source =GenerateByPage(
(previous) =>
let
skipRows = if previous = null then 0 else Value.Metadata(previous)[skipRows],
totalItems = if previous = null then 0 else Value.Metadata(previous)[total],
table = if previous = null or Table.RowCount(previous) = pageSize then
FetchPage(url, pageSize, skipRows)
else null
in table,
type table [Column1])
in
Source
in
FetchPagesMaybe you have a look at it or someelse, that would great!!
Thanks again!
freiburgc
Hi Anonymous ,
Instead of having them all listed in one query, could you please have them created as indicated by me i.e., to create 3 queries and give it a try?
Regards,
A!
- Anonymous5 years agoNot applicable
Hi Anonymous ,
I have created different queries and it almost works now.
Unfortunately another problem has emerged.
I have extracted a customfield of the query and i got a failure.
"Expression Error: Value "null" cannot be converted to Typ List.
Details:
Value=
Type=[Type]
= Table.TransformColumns(#"Erweiterte Column1.fields.customfield_13101", {"Column1.fields.customfield_13100", each Text.Combine(List.Transform(_, Text.From)), type text})Do have an idea how to solve it?
Thanks alot!
freiburgc