Forum Discussion

tb0493's avatar
tb0493
Frequent Visitor
3 years ago
Solved

Using "Count" function in DAX for attribute data

Hello, I'm trying to figure out how to perform these Excel formulas in DAX, I'm thinking it's either using COUNTX or COUNTAX and then getting the percent in a visual. Any help would be appreciated. ...
  • TheoC's avatar
    3 years ago

    Hi tb0493 

    You can use the following:

     

    1. Count all records = COUNTROWS ( 'TableName' )
    2. Count if records "bypassed" = 

    CALCULATE ( 

    [Count all records] ,

    FILTER ( 'TableName' , TableName[Processed Type] = "bypassed" ) )

    3. Divide = DIVIDE ( [Count if records "bypassed"] , [Count all records] , 0 )

     

    Attached is a PBIX File to assist.

     

    Hope this helps 🙂

  • tb0493's avatar
    3 years ago

    Thanks! I will give these a try. 🙂