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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
brianj605
New Member

Pass an iframe query string parameter to a stored procedure

I'm interested in passing a parameter from an iframe query string into a stored procedure using Power BI Report Server.  Is something like this possible?

 

For example:

 

URL: http://myserver/reports/powerbi/Sales?rs:embed=true&__parameter1__=QueryTokenValue123

 

----------------------


let
Source = Sql.Database("x", "x", [Query="exec StoredProcedureName '"& __parameter1__ & "'"])

 

Thanks,

Brian

6 REPLIES 6
pbibeginner5
New Member

Were you able to figure out how to do this? I need the same functionality. Is there a work around? Thanks.

v-qiuyu-msft
Community Support
Community Support

Hi @brianj605,

 

It's possible to do that. Please go through Riccardo Muti (Admin, Microsoft Power BI)'s post here: 

 

Pass filter in URL (Power BI Report Server)

 

Best Regards,

Qiuyun Yu

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

Hi Qiuyun Yu,

 

Thanks for the reply.  I read the Pass filter in URL post, but it looks different than what I am trying to acheve.  From what I can tell, the Pass filter in URL post is about using a query string parameter to cause Power BI to filter data, such as filtering data returned from a stored procedure.

 

What I am looking to do is to pass an arbitrary value (such as a token) from the query string as a parameter value of a stored procedure.  This would allow me a lot flexibility for logic to take place in the stored procedure based on a query string parameter.

 

The query would look something like this:

Source = Sql.Database("x", "x", [Query="exec StoredProcedureName '"& [escaped query string parameter value] & "'"])

 

Thanks,

Brian

Hi @brianj605,

 

I'm afraid it cann't be achieved currently.  @mgmeyer Do you have any idea? 

 

Best Regards,
Qiuyun Yu

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

Ok, thanks for letting me know,

 

Unless @mgmeyer has a solution I'll submit it as an Idea.

 

Thanks,

Brian

@brianj605 & @v-qiuyu-msft

 

6 months have passed since reply on this post. I want to call an JSON endpoint based on the parameter passed in query string. Is this possible in Power BI now? 

 

I am evaluating Power BI usage and testing all features before I can commit.

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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