I have a form with several text and combo boxes. It it set up to allow the user to input criteria and then run a query.
In the criteria area of the query, the criteria of each column is set in the following fashion:
[blue][forms]![my_frm]![my_textbox][/blue]
The problem I'm experiencing is when the textbox is left blank (to pull all records). I've tried using the Nz() function without success. Here's an example:
[blue]Nz([forms]![my_frm]![my_textbox],Is Null or Is Not Null)[/blue]
It seems the only way around this is using the IIF() function; however, this really slow the query down. Can anyone point me in a direction that will help?
Thanks.
-agfon
In the criteria area of the query, the criteria of each column is set in the following fashion:
[blue][forms]![my_frm]![my_textbox][/blue]
The problem I'm experiencing is when the textbox is left blank (to pull all records). I've tried using the Nz() function without success. Here's an example:
[blue]Nz([forms]![my_frm]![my_textbox],Is Null or Is Not Null)[/blue]
It seems the only way around this is using the IIF() function; however, this really slow the query down. Can anyone point me in a direction that will help?
Thanks.
-agfon