Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

Compare value in the same column

Hi

 

I have table below : 

NameGroupValue
A120
B120
120
220
224
312
312
H312
412
420
K424
L412
M412
412

 

I would like to compare the value in the same group, all the values in the same group must be identical == > OK, If not KO 

The result is as below : 

NameGroupValueCoherence
A120OK
B120OK
120OK
220KO
224KO
312OK
312OK
H312OK
412KO
420KO
K424KO
L412KO
M412KO
412KO

thank oyu in advance for your help

3 ACCEPTED SOLUTIONS
Ahmedx
Super User
Super User

pls try this

Column = 
VAR _Result = CALCULATE(DISTINCTCOUNT('Table'[Value]),ALLEXCEPT('Table','Table'[Group]))
RETURN
IF(_Result=1,"OK","KO")

Screenshot_1.png

View solution in original post

Ahmedx
Super User
Super User

pls try this

Column = 
VAR _Result = CALCULATE(DISTINCTCOUNT('Table'[Value]),ALLEXCEPT('Table','Table'[Group]))
RETURN
IF(_Result=1,"OK","KO")

Screenshot_1.png

View solution in original post

danextian
Super User
Super User

Hi @Anonymous ,

 

Try this as a calc column:

Coherence =
IF (
    CALCULATE (
        DISTINCTCOUNT ( 'Table'[Value] ),
        ALLEXCEPT ( 'Table', 'Table'[Group] )
    ) > 1,
    "KO",
    "OK"
)

danextian_0-1695047078997.png

 





Dane Belarmino | Microsoft MVP | Proud to be a Super User!

Did I answer your question? Mark my post as a solution!


"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu or follow my page on Facebook @DAXJutsuPBI.

View solution in original post

3 REPLIES 3
danextian
Super User
Super User

Hi @Anonymous ,

 

Try this as a calc column:

Coherence =
IF (
    CALCULATE (
        DISTINCTCOUNT ( 'Table'[Value] ),
        ALLEXCEPT ( 'Table', 'Table'[Group] )
    ) > 1,
    "KO",
    "OK"
)

danextian_0-1695047078997.png

 





Dane Belarmino | Microsoft MVP | Proud to be a Super User!

Did I answer your question? Mark my post as a solution!


"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu or follow my page on Facebook @DAXJutsuPBI.
Ahmedx
Super User
Super User

pls try this

Column = 
VAR _Result = CALCULATE(DISTINCTCOUNT('Table'[Value]),ALLEXCEPT('Table','Table'[Group]))
RETURN
IF(_Result=1,"OK","KO")

Screenshot_1.png

Ahmedx
Super User
Super User

pls try this

Column = 
VAR _Result = CALCULATE(DISTINCTCOUNT('Table'[Value]),ALLEXCEPT('Table','Table'[Group]))
RETURN
IF(_Result=1,"OK","KO")

Screenshot_1.png

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Kudoed Authors