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

OR statement

Hi every one,

 

I am trying to run this iif in DAX, but I get an error:

 

= iif (OR( [StationName.Value] = "CONGbann01", [StationName.Value] = "CONGccbr01"),

(Fields!DriftCorrection_pH7Value.Value + Fields!DriftCorrection_pH4Value.Value)/2.0,
Fields!DriftCorrection_pH7Value.Value +Fields!DriftCorrection_pH10Value.Value)/2.0)

 Here is the error:

 

The Value expression for the textrun 'DriftCorrection_pH7Value1.Paragraphs[0].TextRuns[0]' contains an error: [BC30201] Expression expected.

 

Also, I included 2 pictures of the variables (circled in red) I am using.

station.png

 

powerbi.png

2 REPLIES 2
Anonymous
Not applicable

Thank you @Dangar332 , it is still the same un fortunately. Do you have more ideas, please?

 

Dangar332
Super User
Super User

hi, @Anonymous 

try 

 

= iif (
     OR( [StationName.Value] = "CONGbann01",
         [StationName.Value] = "CONGccbr01"
     ),
     (Fields!DriftCorrection_pH7Value.Value + Fields!DriftCorrection_pH4Value.Value)/2.0,
     (Fields!DriftCorrection_pH7Value.Value +Fields!DriftCorrection_pH10Value.Value)/2.0
  )

 

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

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

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.