Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
I have two separate dataflows in the same workspace:
Each of the Queries in their dataflows starts with the below code, but #### represents the different environments
let AnalyticsQuery =
let Source = Json.Document(Web.Contents("https://api.applicationinsights.io/v1/apps/####/query",
[Query=[#"query"="customEvents
When I setup credentials, the connection auto-defines as https://api.applicationinsights.io, and cannot seem to be changed. For each one, I put in my API token in the username under Basic (shown as $$$$). This works for authorization.
I setup both dataflows, and each one works. However, when scheduling refreshes overnight (7 minutes queries, an hour apart), one will always fail. I suspect that both dataflows are referencing the same connection, so they are only getting the last Token value that I entered?
Data source credentials are missing or invalid. Please update the credentials for Web in dataflows settings page and try again.
Not sure if I am doing something wrong, or I shouldn't be trying to do things this way?
Solved! Go to Solution.
you need to actively delete the global data source settings for the previous definition. That is cached and will continue to be used unless you remove it.
Hi @lbendlin,
I actually first was using RelativePath, and making flows without it to see if it would change the connection name (it did not). Though maybe there is something in it that I am doing wrong.
let AnalyticsQuery =
let Source = Json.Document(Web.Contents("https://api.applicationinsights.io",
[RelativePath="v1/apps/####/query",
Query=[#"query"="customEvents
But thanks for the idea!
you need to actively delete the global data source settings for the previous definition. That is cached and will continue to be used unless you remove it.
Gotchya. Would that be done in the workbook settings for that dataflow? I cannot find how to remove it from there.
There are 2 credentials here, but the first one is for an unrelated datasource using OAuth.
I guess the next attempt for that would be delete and re-create the dataflows?
(also, when doing all this, would you reccommend I stick with using RelativePath?)
Would that be done in the workbook settings for that dataflow?
no, in the dataflow editor
would you reccommend I stick with using RelativePath?
yes
Awesome, thank you.
I disconnected the credentials here for both (somehow it let me save and close), and now one of them refers to the full query as the connection name. (I couldn't get the other one to clear the cache, but I just needed one to not use the root for the credentials, so it works now!)
Read about the RelativePath option in Web.Contents.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
57 | |
30 | |
24 | |
23 | |
20 |
User | Count |
---|---|
57 | |
37 | |
23 | |
22 | |
20 |