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
Anonymous
Not applicable

Display total row count of a matrix visual

Hi All,

 

I have a matrix visual for which I am extracting a rows, columns and values from an pivot table. I have take employee id as the reference and unpivotted all the other columns and thus left with 3 columns - employee_id, attribute and value.
Now, how do I write a dax expression such that it gives me the correct row count dynamically based on slicer selections.
The function which I wrote is
Row Count = COUNTROWS(SUMMARIZECOLUMNS(Table_Name[ColumnName]))
But it is not giving the right results when I compare the data in Power BI with that of the database.

 

Please suggest how to go about this?

1 REPLY 1
v-jingzhang
Community Support
Community Support

Hi @Anonymous 

 

Can you provide some sample data? Which column is used in the slicer for different selections? What do you want to count rows on? Currently you have employee_id, attribute and value, so which is the ColumnName column used in the current measure? The expected result is not very clear to me so it's difficult to provide a detailed suggestion or solution. 

 

Best Regards,
Community Support Team _ Jing

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.

Top Solution Authors