Forum Discussion

amandabus21's avatar
amandabus21
Icon for Helper V rankHelper V
3 years ago
Solved

Row divided by Total

How can I get my rows to divide by my Total?

 

Example: 

 

The Distinct Count of Equipment (MP) column divided by the total 253. 

 

23/253

21/253, etc

  • Fowmy's avatar
    Fowmy
    3 years ago
    AAA =
    DIVIDE (
        COUNT(TABLENAME[Equipment (MP)]),
        CALCULATE (
            COUNT(TABLENAME[Equipment (MP)]),
            ALLSELECTED ()
        )
    )

3 Replies

  • amandabus21 

    Can try the following measure. You can also include the filed that in your table visual on the very left inside ALLSELECTED 

     

    AAA =
    DIVIDE (
        DISTINCTCOUNT(TABLENAME[Equipment (MP)]),
        CALCULATE (
            COUNT(TABLENAME[Equipment (MP)]),
            ALLSELECTED ()
        )
    )
            

     

  • Hi, 

    This isn't giving me the correct values.

     

    first one should be 23/253 = .091

    second should be21/253 = .830

     

     

    • Fowmy's avatar
      Fowmy
      Icon for Super User rankSuper User
      AAA =
      DIVIDE (
          COUNT(TABLENAME[Equipment (MP)]),
          CALCULATE (
              COUNT(TABLENAME[Equipment (MP)]),
              ALLSELECTED ()
          )
      )