PowerPivot COUNTROWS error message
The COUNTROWS DAX formula in Excel’s PowerPivot add in allows you to count the number of rows that meet your condition/s, typically included in a CALCULATE function. However, you often get a COUNTROWS error message when trying to use it.
Related: Learn how to use PowerPivot
The main reason for this is that you have incorrectly referred to a Table AND Column instead of the required syntax which is only the Table name.
So if the table name is ‘Leave register’ and the column you are thinking about is the number of leave slips handed in shown in the column ‘Leave Slip Number’, you would only need to refer to the table name i.e.
COUNTROWS(Leave register)
and not
COUNTROWS(Leave Register[Leave Slip Number])
PowerPivot’s logic is that in any table the number of rows are the same in all columns so you only need to provide the table name.