Iif with And conditions

L

lg

I want to nest iif statements to check if 3 conditions are as follows:

Field one is null
Field two is not null
Field three is not null

If the condition is met, I want to update a field with "2". otherwise,
leave the field blank.
 
J

John Spencer

Perhaps you are looking for this expression.

IIF(Field1 is null and Field2 is not null and Field3 is not null,2,Null)


If you really want to change the field contents you can use that
expression in an update query.


'====================================================
John Spencer
Access MVP 2002-2005, 2007-2008
Center for Health Program Development and Management
University of Maryland Baltimore County
'====================================================
 
L

lg

EXCELLENT. just what i needed. I used it in an update query to update field
4. THANK YOU!!!
 

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

Top