Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
I have one slicer which contain list of city names whenever i selected the cityname the slicer value need to be passed to the SQL store procedure which will give some result.
My Plan: Slicer value-->Paramater value--> Calling store procedure in M Language(query advance editor)
Please could you let me know how we can pass slicer value to parameter value or slicer value in M language(query advance editor)
Hi @Anonymous ,
The data in SQL Server data source cannot be filtered by the values in the slicer. But you can filter the data by changing the parameters.
First create a query parameter and list all city values.
Refer to https://www.biinsight.com/power-bi-desktop-query-parameters-part-1/
to filter the data source.
Set different parameter values in Desktop:
If the problem is still not resolved, please provide detailed error information or the expected result you expect. Let me know immediately, looking forward to your reply.
Best Regards,
Winniz
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
My list of parameter value will be dynamically changed and i cannot hardcode the values. I am using sql server live connection.
Hi @Anonymous ,
The SQL Server datasource only supports import and direct query mode. Are you using the live connection mode to connect to the published SQL Server dataset?
In addition, in live connection, you cannot and do not need to use query parameters. Because when an interaction occurs, the query is sent directly to the data source. So when you use a slicer, Power BI will filter data in the datasource based on the value of the slicer.
If the problem is still not resolved, please provide detailed error information or the expected result you expect. Let me know immediately, looking forward to your reply.
Best Regards,
Winniz
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
User | Count |
---|---|
77 | |
76 | |
45 | |
31 | |
26 |
User | Count |
---|---|
98 | |
89 | |
52 | |
48 | |
46 |