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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

Nested Calculate

Afternoon,

 

We are currently experiencing a performance issue with the following pattern. Specifically for this test we are looking at the Net Sales TY measure (which enforces DRY programming principles), evualuated in the context of item_long_name (an item name descriptor from a joined table).

 

Unfortunatly, when evaluating we get significant slowdowns.

 

DAX Pattern Current.PNG

 

In order to remedy, we tested a measure as below, which in violation of DRY programming principles (WET).

 

DAX Pattern Testing.PNG

 

Is there another way to write the DAX to appropriately evaluate in context, and still maintain DRY?

 

DAX Pattern Performance.png

 

I'll post more query plans and server timings, if this gains traction.

 
1 REPLY 1
Anonymous
Not applicable

Hi

 

I would recommend a couple of options:

A. Replace the table filters for column filters

B. For those where you need the table filter such as (date) , specified the actual column in your filter:  

 

If I answer your question, please mark my post as a solution, this will also help others.
Please give Kudos for support.

 

Tomas Santandreu Polanco |Principal Business Intelligence Consultant
www.designmind.com

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.