Forum Discussion

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

Checking if all the values are the same

Hello community,   I am working in a measure that shows the contracted speed value for a bus fleet. The key is that all the buses are supposed to have the same value, and this is what I would lik...
  • ValtteriN's avatar
    3 years ago

    Hi,

    You could utilize COUNTROWS and DISTINCT.
    DAX:

    Measure 21 =

    IF(COUNTROWS(DISTINCT('Table (12)'[Column2]))>1,1,0)


    E.g. (non distinct values:

     

    e.g. distinct:

    I hope this post helps to solve your issue and if it does consider accepting it as a solution and giving the post a thumbs up!

    My LinkedIn: https://www.linkedin.com/in/n%C3%A4ttiahov-00001/