Calculated Field on Query with Null Values

Lochwood

Registered User.
Local time
Today, 13:36
Joined
Jun 7, 2017
Messages
130
I am trying to create a calculated filed in query based on the following.

If the date is null then calculated field= No
If the date is not null then calculated field =Yes

here is what i have tried to no avail:

Status: IIf(IsNull([Date]),"No") & IIf(IsNotNull([Date]),"Yes")

The error i get is "Extra ) in query expression"
 
What about:
Code:
Status: IIf(IsNull([Date]),"No","Yes")
 
your syntax is wrong

iif ( condition, value_if_true, value_if_false )

Code:
IIf(IsNull([Date]),"No","Yes")

also note that date is a reserved word
 

Users who are viewing this thread

Back
Top Bottom