P
PC
Hi I'm running a query where one of the criteria contains a like statement.
I'm placing the criteria directly in the query design window.
e.g. The original criteria for the query would appear as: Like
[Forms]![FormFame]![FieldName] & "*". The user can enter all or part of the
word they are searching for and this works fine.
My problem is if the field is left blank all results are returned which I
don't want.
If I try IIf(Not IsNull([Forms]![FormName]![FieldName]), Like
[Forms]![FormName]![FieldName] & "*") nothing is returned whether text is
entered or not.
I'm sure I missing something simple enough but and advise would be
appreciated.
Regards
...pc
I'm placing the criteria directly in the query design window.
e.g. The original criteria for the query would appear as: Like
[Forms]![FormFame]![FieldName] & "*". The user can enter all or part of the
word they are searching for and this works fine.
My problem is if the field is left blank all results are returned which I
don't want.
If I try IIf(Not IsNull([Forms]![FormName]![FieldName]), Like
[Forms]![FormName]![FieldName] & "*") nothing is returned whether text is
entered or not.
I'm sure I missing something simple enough but and advise would be
appreciated.
Regards
...pc