Forum Discussion

thatrick1963's avatar
thatrick1963
Regular Visitor
2 years ago
Solved

ALL() & The error "COUNT function only accepts a column reference as an argument."

Newbie here,

 

I receive this error message when trying to use the ALL() function in following statement.  

The COUNT function only accepts a column reference as an argument.

Measure = count(all('WORK ORDERS'[WO#]))
This is just simple formula to demonstrate the issue.
 
Any help would be appreciated as all potential solutions to my goal of showing percentage of unfiltered total use the ALL() function and all result in the error.
  • thatrick1963's avatar
    thatrick1963
    2 years ago

    Thank you so much for the help.  Although I chose to use COUNTX, your reply guided me there.  The solution that that worked.

    DIVIDE(COUNTX('WORK ORDERS','WORK ORDERS'[WO#]),COUNTX(ALL('WORK ORDERS'),'WORK ORDERS'[WO#]))

3 Replies

    • thatrick1963's avatar
      thatrick1963
      Regular Visitor

      Thank you so much for the help.  Although I chose to use COUNTX, your reply guided me there.  The solution that that worked.

      DIVIDE(COUNTX('WORK ORDERS','WORK ORDERS'[WO#]),COUNTX(ALL('WORK ORDERS'),'WORK ORDERS'[WO#]))