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

To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.

Reply
jsaue003
Frequent Visitor

AND IF in conditional column

Hello.

 

I have three columns with health values (Scope Health, Schedule Health, Budget Health) and four category columns which are supposed to be populated with Path to Green if any of the three columns with health values are other than green. I've tried a custom column with the following: 

 

if [Scope Health] <> "Green" or [Schedule Health] <> "Green" or [Budget Health] <> "Green" 

AND 

[Category 1] <> "Path to Green" or [Category 2] <> "Path to Green" or [Category 3] <> "Path to Green"or [Category 4] <> "Path to Green" 

THEN "Yes"

 

No matter what I swap around I can't get this to say "Yes" correctly. The function itself gives me errors (token THEN expected). How can I achieve this? 

1 ACCEPTED SOLUTION
Greg_Deckler
Community Champion
Community Champion

I believe you want this:

 

if ([Scope Health] <> "Green" or [Schedule Health] <> "Green" or [Budget Health] <> "Green") and [Category 1] <> "Path to Green" or [Category 2] <> "Path to Green" or [Category 3 <> "Path to Green" or [Category 4] <> "Path to Green" then "Yes" else "No"


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

View solution in original post

1 REPLY 1
Greg_Deckler
Community Champion
Community Champion

I believe you want this:

 

if ([Scope Health] <> "Green" or [Schedule Health] <> "Green" or [Budget Health] <> "Green") and [Category 1] <> "Path to Green" or [Category 2] <> "Path to Green" or [Category 3 <> "Path to Green" or [Category 4] <> "Path to Green" then "Yes" else "No"


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

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

Top Kudoed Authors