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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
cdawidow
Helper III
Helper III

OPTIMIZE SUMX MEASURE PERFORMANCE PLEASE HELP!

Hi guys.  I have a basic calculation to model new sales ( New Proposed Sales) based on implementing a product discount ( Proposed Discount) across my customer base and their respective sales history ( based on average quantity sold).  Because I have to iterate across each customers respective average sales data to accomplish my measure, I used SUMX.  The formula is shown below.  The formual works but it is too clunky and I want to optimize it so the memory use is minimized perhaps using virtual tables but I am running into a brick wall and cannot seem to get the answer apart from using SUMX.  Any help would be appreciated !
CLUNKY.PNG

 

2 REPLIES 2
Mohammad_Refaei
Solution Specialist
Solution Specialist

It will help a lot if you share a file with random data.

In general, the if statement in your measure will force the formula engine to operate and will generate a CallBackDataID which impacts the performance.

I don't understand the significance of the Sales[PI], if you can't avoid the condition, try to evaluate it in a variable.

 

lbendlin
Super User
Super User

Are you familiar with DAX Studio?  Use it to analyze the performance of this measure (and all its upstream measures) and then decide if it needs optimizing or not.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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

Top Solution Authors