G
Guest
I would like to formulate a query that will determine if the criterion of a
field is to be Is Null or Is Not Null depending on the data of another field
in equijoined table. I am trying to use the IIf function to build this
criterion in design view using:
IIf([Other_Table]![Determining_Field]="X",Is Not Null, Is Null)
However, the SQL query I get is:
WHERE ...
([This_Table]![This_Field]=(IIf([Other_Table]![Determining_Field]="X",Is Not
Null, Is Null)) ...
which is obviously not what I want to determine but...
WHERE ...
([This_Table]![This_Field] IS {NOT} NULL) ...
Could you please advise me the syntax error that is occuring?
field is to be Is Null or Is Not Null depending on the data of another field
in equijoined table. I am trying to use the IIf function to build this
criterion in design view using:
IIf([Other_Table]![Determining_Field]="X",Is Not Null, Is Null)
However, the SQL query I get is:
WHERE ...
([This_Table]![This_Field]=(IIf([Other_Table]![Determining_Field]="X",Is Not
Null, Is Null)) ...
which is obviously not what I want to determine but...
WHERE ...
([This_Table]![This_Field] IS {NOT} NULL) ...
Could you please advise me the syntax error that is occuring?