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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
Anonymous
Not applicable

what if parameter problem

i want to create a measure using with "what if" parameter with sumx function but i'm getting memory error. how can convert this function. And how can i get the results without using sumx function?

 

SUMX(Daily[NETSPEND],SWITCH(TRUE(),Daily[NETSPEND]=0,0,Daily[NETSPEND]+'PriceIncrease'[PriceIncrease]))

 

My Table consists of 20 columns and 5M+ rows.

 

Best.

1 ACCEPTED SOLUTION
v-robertq-msft
Community Support
Community Support

Hi, @Anonymous 

According to your description, I can roughly understand what you want to get, I’ve also created some test data and create a measure to achieve this, you take a look at my steps and find if it’s useful:

This is my test data:

v-robertq-msft_0-1614309550803.png

 

I created What-if parameter and apply a Slicer on the page, then I created a measure, because calculated column can not be affected by the selection of a slicer:

Measure =

IF(

    MAX([NETSPEND])=0,

    0,

    SUMX('Daily',[NETSPEND]+[Parameter Value]))

Then I created a table chart and place them, this measure can run properly, like this:

v-robertq-msft_1-1614309550816.png

 

You can download my test pbix file here

 

If this result is not what you want, you can post some sample data(without sensitive data) and your expected result so that we can help you in advance.

How to Get Your Question Answered Quickly 

Thank you very much!

 

Best Regards,

Community Support Team _Robert Qin

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

1 REPLY 1
v-robertq-msft
Community Support
Community Support

Hi, @Anonymous 

According to your description, I can roughly understand what you want to get, I’ve also created some test data and create a measure to achieve this, you take a look at my steps and find if it’s useful:

This is my test data:

v-robertq-msft_0-1614309550803.png

 

I created What-if parameter and apply a Slicer on the page, then I created a measure, because calculated column can not be affected by the selection of a slicer:

Measure =

IF(

    MAX([NETSPEND])=0,

    0,

    SUMX('Daily',[NETSPEND]+[Parameter Value]))

Then I created a table chart and place them, this measure can run properly, like this:

v-robertq-msft_1-1614309550816.png

 

You can download my test pbix file here

 

If this result is not what you want, you can post some sample data(without sensitive data) and your expected result so that we can help you in advance.

How to Get Your Question Answered Quickly 

Thank you very much!

 

Best Regards,

Community Support Team _Robert Qin

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Solution Authors