G
Guest
I am trying to create a query based on data entered in a form (the data comes
from drop down lists from multiple tables). Everything is going smoothly,
except for a couple of criteria problems. Some of the form fields may be
left blank while others are filled in. So if in the criteria row under a
particular characteristic I enter <Like [Forms]![frmFieldMatch]![Combo24]>
and under the next characteristic I enter <Like
[Forms]![frmFieldMatch]![Combo34]>, I only get records back where both
critera are true, of course. That's not what I want. My next idea was to
move all my criteria down to the "Or" row. That seemed to work for a little
while, until I reopened the query and they had moved back up to the
"Criteria" row. How do I get around that? Here's a description of the final
results that I'm looking for: I want records returned that have the selected
characteristics entered on the form, but where the form is blank, all's fair.
For example, if I select "elephant" under the "Animal" list and "purple"
under the "color" list, but I do not select a choice under the "size" list, I
should come up with all purple elephants of ANY size, not all purple
elephants with a blank "size" field.
I really hope this makes some kind of sense; let me know if you need more
info.
from drop down lists from multiple tables). Everything is going smoothly,
except for a couple of criteria problems. Some of the form fields may be
left blank while others are filled in. So if in the criteria row under a
particular characteristic I enter <Like [Forms]![frmFieldMatch]![Combo24]>
and under the next characteristic I enter <Like
[Forms]![frmFieldMatch]![Combo34]>, I only get records back where both
critera are true, of course. That's not what I want. My next idea was to
move all my criteria down to the "Or" row. That seemed to work for a little
while, until I reopened the query and they had moved back up to the
"Criteria" row. How do I get around that? Here's a description of the final
results that I'm looking for: I want records returned that have the selected
characteristics entered on the form, but where the form is blank, all's fair.
For example, if I select "elephant" under the "Animal" list and "purple"
under the "color" list, but I do not select a choice under the "size" list, I
should come up with all purple elephants of ANY size, not all purple
elephants with a blank "size" field.
I really hope this makes some kind of sense; let me know if you need more
info.