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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
sfooshee
Regular Visitor

(Calculated column) Count any row if column value = row value

So I've got a COUNTIFS excel formula (calculated) that counts any row that meets multiple criteria, including matching a value on the current row. But it is a calculated column so I can't just use " " to find a value, it needs to match whatever is on the row.

 

My excel formula looks like this:

 

COUNTIFS(AM:AM,"Completed",D:D,[@[Visit Date]],N:N,[@First Name],AO:AO)>0

 

So I need a DAX formula that does that. It can search a column for a value that matches the current row. Any thoughts?

1 ACCEPTED SOLUTION
Vera_33
Resident Rockstar
Resident Rockstar

Hi @sfooshee 

 

It's better to provide some sample data (in a format people can copy) with expected result. I don't understand your COUNTIFS without enough context, but basically you can do DAX calculated column like below, if you have multiple conditions, use &&

Column = COUNTROWS(FILTER('Table','Table'[yourColumn]=EARLIER('Table'[yourColumn])))

OR

Column = 
VAR CurValue = 'Table'[yourColumn]
RETURN
COUNTROWS(FILTER('Table','Table'[yourColumn]= CurValue))

 

View solution in original post

2 REPLIES 2
v-deddai1-msft
Community Support
Community Support

Hi @sfooshee ,

 

Have you sovled your issue? If not, would you please show us some sample data and your expected result. Then we can help you more accurately.

 

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

 

Best Regards,

Dedmon Dai

Vera_33
Resident Rockstar
Resident Rockstar

Hi @sfooshee 

 

It's better to provide some sample data (in a format people can copy) with expected result. I don't understand your COUNTIFS without enough context, but basically you can do DAX calculated column like below, if you have multiple conditions, use &&

Column = COUNTROWS(FILTER('Table','Table'[yourColumn]=EARLIER('Table'[yourColumn])))

OR

Column = 
VAR CurValue = 'Table'[yourColumn]
RETURN
COUNTROWS(FILTER('Table','Table'[yourColumn]= CurValue))

 

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

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

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