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
jha_clevertrack
Frequent Visitor

Using parametre in url rp:

Hi, Im new to power-Bi.

 

I want to use the parametre transfer in url, I have created a parametre in my report called recID, as text and with a value, and in my DirectQuery Im using it directly:

let
    Source = Sql.Database("sql address", "database name", [Query="select * from account_vehicle_online where id ="&recID])
in
    Source

 

And its working when setting the default value in Parametres inside Power-Bi desktop, but when trying to set it from the url when calling the report embedded, its not reading the value:

 

https://app.powerbi.com/reportEmbed?reportId=b361c01e-522f-41e3-95c0-22570dd955cf&rp:recID=2&autoAut...

 

Any suggestions?

Any links to a working sample?

 

Kind regards 

Jan

1 ACCEPTED SOLUTION

Hi @jha_clevertrack ,

 

If you are using common report, we can use the following workaround:

 

1. create a dim table and create relationship between fact table:

 

 

RecordParm = DISTINCT('Table_A'[record])

 

 

13.jpg

 

2. use query string parameter: https://docs.microsoft.com/en-us/power-bi/collaborate-share/service-url-filters

 

14.jpg15.jpg

 

the fact table is still in directquery and will get nessary data based on value of the dim table

 

Update: in addition, the fact table does not use sql statement. Note that if there is no value assigned in url string parameter, it will retrieve all the ids.


Best regards,

 

Community Support Team _ Dong Li
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

3 REPLIES 3
v-lid-msft
Community Support
Community Support

Hi @jha_clevertrack ,

 

It seems like a common report instead of rdl report? Based on this document, the rp: URL parameters can only work for Paginated Reports .Please refer this documentation to get more information about URL parameters in Paginated report.

 

If it is  actually a rdl report, please try to change the parameter to refresh data when changed.

 

8.jpg

 


Best regards,

 

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

Thanks alot for the answer, so this param transfer is only possible in rdl, and not in common reports?

Any other ways to make a parametre transfer in common reports, we need the DirectQuery and interactivity.

 

Kind regards

Jan

Hi @jha_clevertrack ,

 

If you are using common report, we can use the following workaround:

 

1. create a dim table and create relationship between fact table:

 

 

RecordParm = DISTINCT('Table_A'[record])

 

 

13.jpg

 

2. use query string parameter: https://docs.microsoft.com/en-us/power-bi/collaborate-share/service-url-filters

 

14.jpg15.jpg

 

the fact table is still in directquery and will get nessary data based on value of the dim table

 

Update: in addition, the fact table does not use sql statement. Note that if there is no value assigned in url string parameter, it will retrieve all the ids.


Best regards,

 

Community Support Team _ Dong Li
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