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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.

Reply
Anonymous
Not applicable

DAX optimization with what-if parameters

Hello,

 

I put together a proof of concept dashboard that takes into account numerous user inputs.  THe functionality works great, however the performance is terrible. My Tables take a long time to refresh with the user input data (what-if parameters).

 

 

 

Revenue_User_Input = 
    IFERROR(
        SUMX(
        DISTINCT('New Allocation'[Product]),
            SWITCH([Product],
                "Product1", ([Revenue] * [% Product1 Allocation Value]),
                "Product2", ([Revenue] * [% Product2 Allocation Value]),
                "Product3", ([Revenue] * [% Product3 Allocation Value]),
                "Product4", ([Revenue] * [% Product4 Allocation Value]),
                "Product5", ([Revenue] * [% Product5 Allocation Value]),
                "Product6", ([Revenue] * [% Product6 Allocation Value])
    )),0)

 

 

New Allocation[Product] is a measure that refers to the calculated table I used to pull the specific products I needed.  I did this so that I could add in a total column (used elsewhere) and an additional product that is not yet in my base data (new product will be launched in the future).

 

New Allocation = VALUES('Product Reference'[Product])

Product Reference = 
UNION( 
    VALUES('Base Table'[Product]), 
    ROW("Column1"," Total"), 
    ROW("Column1","Product6")
)

 

 

Have tried a few ways of working around this, but they all have similar performance issues.

 

Any help is greatly appreciated!

1 REPLY 1
v-frfei-msft
Community Support
Community Support

Hi @Anonymous ,

 

Kindly share your sample data and excepted result to me if you don't have any Confidential Information. Please upload your files to One Drive for Business and share the link here.

 

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others 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 Kudoed Authors