iif

G

Guest

I have the following expression

GGWPERSQFT: IIf(IsNull([SALEPRIC]),[LSPRC]/[APPGSQFT],[SALEPRIC]/[APPGSQFT])

but I want to add:
if [appgsqft] is zero, then null

otherwise IIf(IsNull([SALEPRIC]),[LSPRC]/[APPGSQFT],[SALEPRIC]/[APPGSQFT])
 
T

tina

do it exactly the way you wrote it, as

IIf([appgsqft] = 0, Null,
IIf(IsNull([SALEPRIC]),[LSPRC]/[APPGSQFT],[SALEPRIC]/[APPGSQFT]))

this is a "nested" IIf statement; note the two parentheses at the end.

hth
 

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