Get certified for free when you join Fabric Data Days 2026 and dive into Fabric, Power BI, SQL, AI, and other essential data skills.
Join nowData Days is here! Join us now for 60+ days of learning, challenges, and connection. Learn more
Hi.
I am developing a report for the financial sector with the aim of monitoring the default rate. To do this, I created a stored procedure that organizes the database, allowing the SQL program to return outstanding securities considering that specific date when a base date is entered.
The report is designed to visualize the default status of customers up to a certain date (base date). Therefore, it is necessary to provide a parameter whenever the report is analyzed, ensuring that the information is updated and consistent with the desired period. However, I am unable to pass a parameter from a slitter, for example, to the query.
This is just a draft with some items that will be used, it is far from being the final version of the front-end.
I would like to know if it is possible via Power BI to pass parameters from a slicer to Power Query.
In Power Query I can pass a fixed parameter, but I was unable to interact with a parameter selected in the Parameter field (Data set).
Solved! Go to Solution.
Consegui resolver usando funรงรฃo do SQL server.
Consegui resolver usando funรงรฃo do SQL server.
You should be able to add a line to your Query1 to format the SQL query. The use that line in the query call.
queryText = "EXEC sp_GetTitulos '" & dataset & "'",
Source = Sql.Database(SERVERNAME, DATABASENAME, [Query=queryText]
Proud to be a Super User! | |
I don't know if I understood. I summarized the M instruction and changed it according to your guidance and it works.
let
datasetOriginal = Text.From(Parameter1),
queryText = "EXEC sp_GetTitulos " & datasetOriginal,
Source = Sql.Database("SERVER", "DATABASE", [Query = queryText])
in
Source
However, I didn't understand how to change it dynamically in Power BI.
I need to pass the parameter dynamically from Power BI to Power Query.
Don't miss out on Data Days, June 15 through August 7. Learn Fabric, Power BI, SQL, AI and more.
Check out the May 2026 Power BI update to learn about new features.
| User | Count |
|---|---|
| 23 | |
| 21 | |
| 20 | |
| 19 | |
| 13 |
| User | Count |
|---|---|
| 58 | |
| 52 | |
| 37 | |
| 31 | |
| 27 |