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

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes! Register now.

Reply
sivarajan21
Post Prodigy
Post Prodigy

Dax to sum a value column based on two filters

Hi,

 

I have the below table :

sivarajan21_0-1693473242269.png

I need to sum the value column with respect to TargetType =0 and their corresponding Value Type.

My dax takes is as below:

Target Unit =
CALCULATE (
SUMX ( Target, Target[Value] ),
FILTER ( Target, Target[TargetType] = 0 )
)

 

This dax takes into consideration TargetType =0 but not Value Type. I have multiple Value Type such as Value_03,Value_02,Value_01 upto Value_12.

 

Could you please help me?

PFA raw excel file test.xlsx

Please let me know if you need further info!

 

Thanks in advance!

@Ahmedx @Greg_Deckler @grantsamborn @amitchandak @Sergii24 

1 ACCEPTED SOLUTION
Ahmedx
Super User
Super User

plse thr this

CALCULATE (
SUMX ( Target, Target[Value] ),
Target, Target[TargetType] = 0 && Target[Value Type] in {"Value_01","Value_02","Value_3","Value_12" } )

View solution in original post

3 REPLIES 3
sivarajan21
Post Prodigy
Post Prodigy

Hi Sir,

 

I have accepted it as a solution!

Thank you!

 

Ahmedx
Super User
Super User

plse thr this

CALCULATE (
SUMX ( Target, Target[Value] ),
Target, Target[TargetType] = 0 && Target[Value Type] in {"Value_01","Value_02","Value_3","Value_12" } )

Hi @Ahmedx ,

 

Amazing solution! thanks,

I will have a look and get back sir

 

Thanks

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 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
Top Kudoed Authors