Forum Discussion
Anonymous
3 years agoNot applicable
"Dataset includes a dynamic data source" Dynamic date in Web Source (No API)
I can't refresh dataset once it's been published because of this error. I cannot seem to find a workaround that suits my needs. The below example is grabbing a table from the web successfully in ...
PhilipTreacy
3 years agoSuper User
Hi Anonymous
The root URL can't be dynamic, it needs to be a fixed string. You can supply dynamic parts of the URL using RelativePath like this
Origen = Json.Document(
Web.Contents(
"https://www.example.com/data/type/date:",
[RelativePath=Date.ToText(DateTime.Date(DateTime.LocalNow()), "yyyy-MM-dd"]
)
),
regards
Phil
Anonymous
3 years agoNot applicable
Hi Phil,
Thanks for your response, I'm running into a new issue with that - "Expression.SyntaxError: Token ',' expected."
Any ideas, on how to resilve that?
- slorin3 years agoSuper User
Hi
...[RelativePath=Date.ToText(DateTime.Date(DateTime.LocalNow()), "yyyy-MM-dd")])),
Stéphane
- Anonymous3 years agoNot applicable
Hi Stéphane,
Thanks, I tried this and got this new error:
DataSource.Error: The downloaded data is HTML, which isn't the expected type. The URL may be wrong or you might not have provided the right credentials to the server.