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

Get certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now

Reply
Anonymous
Not applicable

Embedding Paginated Report with a Power BI Dataset

Hello. I am trying to embed a paginated report in my web application that uses a Power BI Dataset as its datasource. I can get the embed token, but when rendering it, I am getting this error: 

 

dustinetoleteey_0-1594834990163.png

 

The dataset being used and the paginated report are on the same Power BI workspace. 

 

Any help will be appreciated. 

 

24 REPLIES 24
pbi-master
Regular Visitor

Hello.

Any update on this issue? We are having the same problem and looking forward for the solution.

Embedding paginated reports based on Power BI shared datasets in the "App Owns Data" scenario is really important thing in our bisness application.

Any ETA of fixing it and getting rid of this annoying limitation?

 

Currently we are getting the error below while rendering embedded paginated report:

Code: "RSWorkloadError"
ErrorCode: "Discover_DMTS_Error_Unknown"
Message: "There was an error contacting an underlying data source. Manage your credentials or gateway settings on the management page. Please verify that the data source is available, your credentials are correct and that your gateway settings are valid."

 

Actually this capability is rolling out this week, so should be available in all regions by beginning of next week.

You will have to use https://docs.microsoft.com/rest/api/power-bi/embed-token/generate-token for generating the embed token, specify the DatasetId in the request with xmlaPermissions=ReadOnly (https://docs.microsoft.com/rest/api/power-bi/embed-token/generate-token#generatetokenrequestv2datase...)

avive
Power BI Team
Power BI Team

We are marching towards having this available by Jan in production

Hope this helps

Aviv

 

Well, it's January 10th, so is going to be Jan or when do you think?  Just wanted a guesstimate is all.

Please give it another week

Thanks

Aviv

AmosHersch
Microsoft Employee
Microsoft Employee

This is now available. You should use the latest .Net SDK, see some guidance here:

https://docs.microsoft.com/en-us/power-bi/developer/embedded/embed-paginated-reports?tabs=customers#...

 

Thanks,

Amos

Trying to test this out this feature in paginated reports using the embed .NET example code locally, and getting the error: 

 

Could not connect to the data source.

There was an error contacting an underlying data source. Manage your credentials or gateway settings on the management page.
 
Both the report and underlying dataset are in the same workspace which is attached to a premium per capacity.  Able to embed and reach the dataset in regular Power BI reports embedded, so the gateway is okay - using ServicePrincipal.
Anonymous
Not applicable

So, we have implemented the code in our .net application and we are able to see our paginated report through our embedded web application. However, we are seeing an issue where the provided EffectiveIdentity username is not showing correctly in the Paginated Report's username parameter. This parameter is showing the &User.UserId property, however, this value has the service principal GUID instead of the effective identity username provided in the api call. Code in call: 

 

generateTokenRequestV2Parameters = new GenerateTokenRequestV2(datasets: dataSetIdV2, reports: reportIdV2, identities: new List<EffectiveIdentity> { new EffectiveIdentity(username: upn, roles: new List<string> { roleName }, datasets: new List<string> { dataSetId }) });

 

accessToken = client.EmbedToken.GenerateToken(generateTokenRequestV2Parameters);

 

The upn value in this case is my email address 'xxxxx.xxxxxx@xxxx.com', which should show up in the pagainated report parameter for &User.UserId instead of the SPN GUID.

Hi,

 

When you provide an effective identity in the generateToken request it should either be an effective identity for the paginated report or an effective identity for the Power BI dataset.

If you want the username to be the identity passed to the report then should should provide the reportId and not the datasetId. Something like this:

 new EffectiveIdentity(username: upn, , reports: new List<string> { reportId })

In addition you can specify another identity for the dataset, with the roles, etc.

 

Thanks,

Amos

Anonymous
Not applicable

Thank you, that was very helpful. In order to make it work, I had to provide both identities (one for report, one for dataset) otherwise I would get a bad request error. Would you happen to have any documentation on using multiple identities? I don't think I would have ever thought to do that, so thank you.

Can you please share the sample request which worked. I tried multiple ways but still getting badrequest error. for paginated report embedded in powerbi report. I am passing both the report Ids with one dataset

Glad to hear it worked for you.

I don't think there's a documentation for the case of multiple identities, there's a request sample for 2 identities for 2 different datasets, but that's a different case

https://docs.microsoft.com/en-us/rest/api/power-bi/embed-token/generate-token#generate-embedtoken-fo...

We might add such a sample request for the case of paginated report + Power BI dataset in the future.

I think you do need to add that sample for power bi data set and paginated report as soon as you can as people will use this once they move to power bi datasets more and more.

u02cm62
Helper V
Helper V

Can we get an update on this issue and when it will be fixed?

I'm not on the paginated reports team any longer, so I'm not sure when this will be addressed, though I believed it should have been rolled out by now.  @avive might know the latest.

Anonymous
Not applicable

Ah, I am also trying to do the same thing.

1. Able to build, and view the report went built against a PBI dataset

2. Able to publish the Paginated Report to PBI Workspace - Also works fine, and renders, views, etc the PBI dataset.

3. When embedding, the token etc is generated fine;  However, the DYNAMIC DataBinding V2 token generation methods do NOT work.

4. When loading into embedded application, same error as yours. The is BS for sure. 

5. When I use the token from the Paginated sample, all embeddes fine.

6. Clearly something not tested, broken or such thing with Embedded PBI datasets.

7. The other obvious issue is the ability to dynamically bind dataset to PowerBI paginated reports.

8. This dynamic binding is really the only way to make SaaS multi-tenant applications with 10s of thousands tenants viable - ie same report, many different dynamic datasets. - 

 

@chrisfin Help ?

It is a known limitation when embeddeding a paginated report in the "app owns data" scenario - @avive and team are working to unblock that in the coming months.

Anonymous
Not applicable

Chris - Any headway on "app owns data" for embedded paginated reports - Phil

The team that owns this hasn't yet been able to fund the work, so right now it won't happen until sometime in 2021 it looks like.

Anonymous
Not applicable

Hi Chris,

 

Just wanted to check if there are any news on this front? My organization is using shared PBI datasets for paginated reports which aren't supported for embedding at the moment, so just wanted to check if this might change soon before taking the route of completely redesigning data sources.

Helpful resources

Announcements
November Carousel

Fabric Community Update - November 2024

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

Live Sessions with Fabric DB

Be one of the first to start using Fabric Databases

Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.

Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early Bird pricing ends December 9th.

Nov PBI Update Carousel

Power BI Monthly Update - November 2024

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

Top Kudoed Authors