Hello,
I have a form which refers to a query I have which looks at a couple of related tables.
Right now the form has a list box which shows the results of the query. The form also has a handful of text boxes, which, when data is entered into them, the query is re-run and the results in the list box are updated to reflect those values. The criteria in the query are mainly like this for several fields: Like '*' & [Forms]![FormName]![TextBox] & '*'. All of this works fine. However, one of the main tables the query is running against has some NULL values in some of the fields. For example, there is a date field and the query criteria is something like this: >=[Forms]![FormName]![DateTextBox].
The problem I'm running into is that any of the records that contain a null in this date field are being excluded from the list box even before any data is entered into the search box. I can certainly go into the query and modify it to include "OR IS NULL", however then when some data is entered in the text box it won't then filter out the null value rows from the list box.
I guess my question boils down to this: How can I get my query/list box to return all data for a given field until some data is entered into the search box, then, only display the data matching what was entered into the search box? Is this possible or am I trying to go about it the wrong way and there is some other better way to go about it? I'm open to suggestions.
Thank you for taking the time to read my question and for any possible help!