Forum Discussion
Dynamic Data Source Error / RelativePath / Cursor Pagination / Headers
Hi,
I need help updating my data source in the cloud.
The problem is that it is a dynamic data source with headers and Cursor pagination.
I have investigated the use of RelativePath but cannot get it to work on the following.
Can anyone help find the error or an alternative solution.
Some of the headings are in Danish but the coding is in English.
XXX is the token
let
Kilde = List.Numbers(250000,160,1000),
#"Konverteret til tabel" = Table.FromList(Kilde, Splitter.SplitByNothing(), null, null, ExtraValues.Error),
#"Ændret type" = Table.TransformColumnTypes(#"Konverteret til tabel",{{"Column1", type text}}),
#"Tilføjet brugerdefineret" = Table.AddColumn(#"Ændret type", "Brugerdefineret", each Json.Document(Web.Contents("https://apis.e-conomic.com/bookedEntriesapi/v3.2.0/booked-entries?cursor="&[Column1], [Headers=[#"X-AppSecretToken"="XXX", #"X-AgreementGrantToken"="XXX"]]))),
Hi MichaelMM
I tinkered around a bit and I was able to "Test connection" in the Power BI Service with this version of the query:
let Kilde = List.Numbers(250000, 160, 1000), #"Konverteret til tabel" = Table.FromList(Kilde, Splitter.SplitByNothing(), null, null, ExtraValues.Error), #"Ændret type" = Table.TransformColumnTypes(#"Konverteret til tabel", {{"Column1", type text}}), #"Tilføjet brugerdefineret" = Table.AddColumn( #"Ændret type", "Brugerdefineret", each Json.Document( Web.Contents( "https://apis.e-conomic.com", [ RelativePath = "bookedEntriesapi/v3.2.0/booked-entries", Query = [cursor = [Column1]], Headers = [#"X-AppSecretToken" = "XXX", #"X-AgreementGrantToken" = "XXX"] ] ) ) ), //...Does this work for you?
4 Replies
- OwenAugerSuper User
Hi MichaelMM
I tinkered around a bit and I was able to "Test connection" in the Power BI Service with this version of the query:
let Kilde = List.Numbers(250000, 160, 1000), #"Konverteret til tabel" = Table.FromList(Kilde, Splitter.SplitByNothing(), null, null, ExtraValues.Error), #"Ændret type" = Table.TransformColumnTypes(#"Konverteret til tabel", {{"Column1", type text}}), #"Tilføjet brugerdefineret" = Table.AddColumn( #"Ændret type", "Brugerdefineret", each Json.Document( Web.Contents( "https://apis.e-conomic.com", [ RelativePath = "bookedEntriesapi/v3.2.0/booked-entries", Query = [cursor = [Column1]], Headers = [#"X-AppSecretToken" = "XXX", #"X-AgreementGrantToken" = "XXX"] ] ) ) ), //...Does this work for you?
- v-nmadadi-msftCommunity Support
Hi MichaelMM
I wanted to check if you had the opportunity to review the information provided. Please feel free to contact us if you have any further questions.
Thank you. - v-nmadadi-msftCommunity Support
Hi MichaelMM
May I check if this issue has been resolved? If not, Please feel free to contact us if you have any further questions.
Thank you - v-nmadadi-msftCommunity Support
Hi MichaelMM ,
As we haven’t heard back from you, we wanted to kindly follow up to check if the suggestions provided by the community members for the issue worked. Please feel free to contact us if you have any further questions.
Thanks and regards