Using "IF" and "OR" statements in a query...

Luke_Murphy

New member
Local time
Today, 23:45
Joined
Sep 22, 2004
Messages
9
Can this be done?

I want to say that if a field equals one of 4 criteria, so If(or(x=1,x=2,x=3,x=4), THEN perform a certain calculation ELSE perform another calculation. I've got the formula in Excel...

If(or(x=1,x=2,x=3,x=4),y+z,a+b)

...but I'm not sure how to get this to work in Access

Can anyone help?

Thanks in advance!
Luke
 
Code:
=IIf(X IN(1,2,3,4),Y+Z,A+B)
 
In the solution formula:

=IIf(X IN(1,2,3,4),Y+Z,A+B)

What comes between X and IN ?!?

Thanks.
 

Users who are viewing this thread

Back
Top Bottom