View Full Version : IIF query question


jaugermeister
04-16-2009, 10:07 AM
Hey gang, I'm pretty wet behind the ears when concerning SQL or VB coding but far enough to perform simple queries and macros. However this current problem I can't figure out.

What I'm trying to do is a nested IIF query that searches a field for 2 key words and if there is a match then display XYZ, else Unknown.

example:

Reason: IIf([REV] Like "*XX* OR *YY*","XY","Unknown")

this example doesn't work, how can I rewrite this to work?

Thanks in advance!

pbaldy
04-16-2009, 10:14 AM
Try

Reason: IIf([REV] Like "*XX*" OR [REV] Like "*YY*","XY","Unknown")

jaugermeister
04-16-2009, 10:16 AM
dude youre awesome. thanks

pbaldy
04-16-2009, 10:19 AM
No problem; welcome to the site by the way!