IIF "and" statement

  • Thread starter Thread starter slotmgr70
  • Start date Start date
S

slotmgr70

I'm trying to create a simple IIF state ment that looks at two seperate
fields and returns a code. For example:

IIF [revenue]>=500 AND [territory]="Inner Market", "BD_500IN", "BD_500"

I know this isn't right because I tried it a bunch of different ways and
keep getting errors. What is the correct IIF statement for using two
arguments?
 
It might help us diagnose what's happening if you'd tell us what's happening
(i.e., the error messages).

Is there any chance that your [territory] field is defined in its table as a
"lookup" datatype?

Have you tried including [revenue] and [territory] as fields in your query
to see what is actually in those fields?

Regards

Jeff Boyce
Microsoft Office/Access MVP
 
Did you try it like this ---
IIF([revenue]>=500 AND [territory]="Inner Market", "BD_500IN", "BD_500")
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top