Forum Discussion
KUK1390
3 years agoFrequent Visitor
PowerBI - Relative Path
Hi everybody, I wondering if anyone can help me please, I am trying to amend my code to use Relative Path. I have spent a few weeks setting up this report up but when I went to refresh the sou...
- 3 years ago
I think the code may look like this:
(page as number) as record => let Source = Web.Contents( "https://BP.com/public-api", [ RelativePath = "testings/order-service/order/" & Number.ToText(page) & "-" & Number.ToText(page+199), Query = [includeOptional="customFields,nullCustomFields,postalAddresses"], Headers=[#"bp-app-ref"="kieran", #"bp-account-token"="token"] ]), json_doc = Json.Document(Source) in json_doc
KUK1390
3 years agoFrequent Visitor
Hi,
I am still struggling to convert the above code. I keep getting errors. I will post my code shortly.
jbwtp
Memorable Member
3 years agoI think the code may look like this:
(page as number) as record =>
let
Source = Web.Contents(
"https://BP.com/public-api",
[
RelativePath = "testings/order-service/order/" & Number.ToText(page) & "-" & Number.ToText(page+199),
Query = [includeOptional="customFields,nullCustomFields,postalAddresses"],
Headers=[#"bp-app-ref"="kieran", #"bp-account-token"="token"]
]),
json_doc = Json.Document(Source)
in
json_doc