Check your eligibility for this 50% exam voucher offer and join us for free live learning sessions to get prepared for Exam DP-700.
Get StartedDon't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.
Hi Power BI experts,
Would like to know if some one has suggestion on pass "what if paramter" to Power query, and then pass it to SQL Server stored procedure. I have tried way community provided, that's report designer pre-defined parameter value in Power BI Desktop.
SQL Stored Procedure
But considering use defined paramter, I'm thinkg What If parameter, but when I replace parameter name into Advanced Query, it not works.
let
= Sql.Database("JU-NB", "AdventureWorks2016", [Query="EXEC [dbo].[usp_GetTransactionHistory] @sdate = '" &syear &"-" &smonth & "-" & sdate & "',@edate='2013-08-02'"])
It will have error.
Can someone has any suggestion of the workaround? Thank you.
Solved! Go to Solution.
Hi @juchen ,
Your demand is a good idea, while it is not supported to use What-if parameter in Advanced Editor in Power BI currently. You can post your new idea in Idea Forum , to improve the Power BI.
It is a place for customers provide feedback about Microsoft Office products . What’s more, if a feedback is high voted there by other customers, it will be promising that Microsoft Product Team will take it into consideration when designing the next version in the future.
Best Regards,
Amy
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @juchen ,
Your demand is a good idea, while it is not supported to use What-if parameter in Advanced Editor in Power BI currently. You can post your new idea in Idea Forum , to improve the Power BI.
It is a place for customers provide feedback about Microsoft Office products . What’s more, if a feedback is high voted there by other customers, it will be promising that Microsoft Product Team will take it into consideration when designing the next version in the future.
Best Regards,
Amy
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @juchen
You can not pass what-if parameters back to SQL server, you load all your data into a model on refresh, from there you use the only model as your data source.
If you want to reflect all the changes in you SQL DB you can use direct query mode, where you do not need to worry about passing parameters as DAX is folded into SQL on the fly, so filter context is translated into SQL.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Prices go up Feb. 11th.
Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.
User | Count |
---|---|
143 | |
85 | |
66 | |
51 | |
45 |
User | Count |
---|---|
216 | |
89 | |
82 | |
66 | |
57 |