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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
zoeanne7
Frequent Visitor

Countrows in a table with "Y"

Hi! 

 

Forgive me, this is probably really easy but I'm still relatively new to DAX and have to ggogle everything... I have a table with columns Jun - Mar (rows are staff members) with "Y" or "N" in, dependent on whether the staff member has completed a form each month. I'm struggling to find a DAX to look at the whole table and count the total number of "Y"'s without having to filter each column individually within the DAX. Can anyone advise please?

zoeanne7_0-1691090611536.png

Many thanks

1 ACCEPTED SOLUTION
tamerj1
Super User
Super User

Hi @zoeanne7 

you need to first unpivot the table in power query. The 10 columns would be converted into one attribute column (month) and one value column (Y or N). Then a simple CONTROWS - FILTER will do. 

View solution in original post

2 REPLIES 2
tamerj1
Super User
Super User

Hi @zoeanne7 

you need to first unpivot the table in power query. The 10 columns would be converted into one attribute column (month) and one value column (Y or N). Then a simple CONTROWS - FILTER will do. 

Thank you so much, that has revolutionised my report! 

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

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