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
daviidkovacs
New Member

How to pass parameters to the SQL statement from the embedded app?

Hi,

 

I'm new to the PBI services so my question might be a bit silly but I'm a bit lost.

 

TLDR

Is it possible to pass parameter to the SQL query from the app over the PBI API to display the report? What would be the best way to do that?

 

Current stack

  • In the PBI Desktop we have reports and the SQL queries are sitting there.
  • The published reports are in the PBI services in a Workspace.
  • We have a single page application with it's own login and role system where we'd like to display the reports.
  • We also have an API (in Azure Funtions) what get's all the embedTokens and embedLinks for the reports in a specific group from the PBI services.
  • Until this point everything works fine however the report contains everybody's data.
  • So I'm wondering would it be possible to pass a param to the SQL query from the app to update the report?

Goal

When the user logs in the app knows the group ID he belongs to. The displayed report should be based on that specific ID and the user should not be able to see any other results.

 

I imagined something like:

  • The report runs the SQL query with the passed param and the embedded report would update.

 

This might be not the best approach but how could we achieve that? Is it even possible to dynamically update the SQL query from the app/API?

 

if not, how could I display the data based on the user's role?

 

Thank you in advance,

Regards

David

 

0 REPLIES 0

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.