Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
wei_stupid
Frequent Visitor

How to change connected Azure Table account with pbix file or REST API

Hi!

I am trying to change connected Azure Table account programmatically, as I want to setup reports and dataset on behalf of customers. That is to say, I want to push my own designed reports to customer's powerbi, and let its dataset connect to customer's Azure Table. Both Azure Tables have identical schema as I create them.

 

I found out two ways, both promising but seems impossible.

 

The first way is to unzip pbix file and modify (account, connectionString) pair. I inspected subfiles in pbix, and I am guessing the subfile named "SecurityBindings" contains the "connectionString" (credential or something like), but its seems in binary and unreadable, and I am stucked with its format. I think the security shall not rely on file format like the security of crypto shall rely on "key" instead of "algorithm". Can anyone give me some advice to get around this ?

 

The second way is to use "UpdateDatasource" REST API, but it seems that this API does not support datasource of Azure Table.

 

Can anyone help me ? Thank you!

1 ACCEPTED SOLUTION
v-yuezhe-msft
Employee
Employee

@wei_stupid,

It doesn't support to change the connection strings in the zip folder or use the "UpdateDatasource" REST API as you describe. There is a similar idea about this issue, please vote it up.

In your scenario, I would recommend you create source parameter in your PBIX file, the  generate a PBIT file for your customers.

Regards,
Lydia

Community Support Team _ Lydia Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

5 REPLIES 5
v-yuezhe-msft
Employee
Employee

@wei_stupid,

It doesn't support to change the connection strings in the zip folder or use the "UpdateDatasource" REST API as you describe. There is a similar idea about this issue, please vote it up.

In your scenario, I would recommend you create source parameter in your PBIX file, the  generate a PBIT file for your customers.

Regards,
Lydia

Community Support Team _ Lydia Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

@v-yuezhe-msft,

 

Thank you first, I have tried "source parameter", and I failed for Azure Table as datasource. Because I can only set "account" as parameter, but I cannot set "accountKey" as parameter. I find no way to place "accountKey" in "Edit Queries".

Are you sure that "source parameter" works for Azure Table ?

 

Thank you anyway!

 

@wei_stupid,

It is not possible to create a accountkey parameter. Do you generate a PBIT? When the user open the PBIT that conatins account parameter, a new Power BI Desktop file will be created, containing the actual data based on current user’s credentials for the data source.

Regards,
Lydia

Community Support Team _ Lydia Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

@v-yuezhe-msft,

 

Yeah, I understand and I have tried it. But it still requires cusotmer to interact with Power BI Desktop. My ultimate purpose is to let customer interact with Power BI Service through browser only, after I setup reports and dataset for customers programmatically.

 

Finally, I strongly recommend introducing new API to update accountKey, for which I have spent three days trying to get around and finally failed.

 

Thank you anyway!

@wei_stupid,

You can vote the idea in my first reply.

Regards,
Lydia

Community Support Team _ Lydia Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors
Top Kudoed Authors