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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
GellaiTamas
Helper I
Helper I

DAX_Filtered division within one column

Hi,

 

I have many columns in an SQL DB table and these 2 among them: [Property] and [Value].  [Property] has ~30 different items.

How can I divide only 2 specific properties? I'm not quite sure how an SQL WHERE clause could be translated into DAX. I've tried this measure without success:

 

InflationPerCostBase = CALCULATE(
	DIVIDE(
		SUM('Report1 (2)'[Value]);
		SUM('Report1 (2)'[Value])
	);
	FILTER(
		'Report1 (2)';
		'Report1 (2)'[Property] = "AOP Inflation" &&
		'Report1 (2)'[Property] = "AOP Cost Base" 
	)
)

 

What is the best practice here?

 

Thanks,

Tamás

1 ACCEPTED SOLUTION
v-jiascu-msft
Microsoft Employee
Microsoft Employee

@GellaiTamas,

 

Hi Tamás,

 

We can evaluate the totals separately. Try this formula please.

InflationPerCostBase =
VAR AOPInflation =
    CALCULATE (
        SUM ( 'Report1 (2)'[Value] );
        'Report1 (2)'[Property] = "AOP Inflation"
    )
VAR AOPCostBase =
    CALCULATE (
        SUM ( 'Report1 (2)'[Value] );
        'Report1 (2)'[Property] = "AOP Cost Base"
    )
RETURN
    DIVIDE ( Inflation; CostBase; 0 )

Best Regards!

Dale

Community Support Team _ Dale
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

2 REPLIES 2
v-jiascu-msft
Microsoft Employee
Microsoft Employee

@GellaiTamas,

 

Hi Tamás,

 

We can evaluate the totals separately. Try this formula please.

InflationPerCostBase =
VAR AOPInflation =
    CALCULATE (
        SUM ( 'Report1 (2)'[Value] );
        'Report1 (2)'[Property] = "AOP Inflation"
    )
VAR AOPCostBase =
    CALCULATE (
        SUM ( 'Report1 (2)'[Value] );
        'Report1 (2)'[Property] = "AOP Cost Base"
    )
RETURN
    DIVIDE ( Inflation; CostBase; 0 )

Best Regards!

Dale

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

Hi @v-jiascu-msft,

 

Great stuff, it works. Thanks a million!

 

Cheers,

Tamás

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 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.

Top Solution Authors