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

Power BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.

Reply
AlexChampion
Frequent Visitor

What If Parameter - how to use in a calculated column?

Hi All,

 

In my PBI report, I have a table "dash_Monthly_7E" which looks like this:

AlexChampion_0-1630571749049.png

 

The calculated column "Month Start Date" has the following formula:

AlexChampion_1-1630571880960.png

 

The "As At Date" object is a What-If Parameter that the user can define when viewing the report.

 

I need the table to update the dates in column "Month Start Date" when a date value is entered into the What-If Parameter.

 

This currently isn't working, and the EOMONTH function is using today's date, instead of the value in the parameter.

 

I have read that this is because What-If Parameters cannot be used in calculate columns, which "Month Start Date" is.

 

So I think I understand the problem, does anyone know any workarounds please?

 

Thank you. 

1 ACCEPTED SOLUTION
AlexChampion
Frequent Visitor

I have managed to resolve this issue.

I simply recreated the table "dash_Monthly_7E" and replaced all of the calculated columns with measures. The measures are able to  use the What-If parameter in their DAX code and so it works now.

 

 

View solution in original post

1 REPLY 1
AlexChampion
Frequent Visitor

I have managed to resolve this issue.

I simply recreated the table "dash_Monthly_7E" and replaced all of the calculated columns with measures. The measures are able to  use the What-If parameter in their DAX code and so it works now.

 

 

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

Check out the June 2025 Power BI update to learn about new features.

June 2025 community update carousel

Fabric Community Update - June 2025

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