Setting up a parametric query to select everything

  • Thread starter Thread starter Pawel
  • Start date Start date
P

Pawel

Hello,

I have a problem. I have created a parametric query and as
a criteria I have set up a value from combo box.
Everything works fine as long as I am choosing something
in combo box. What I need is to force somehow query to
return every record when nothing is selected in combo box.

Thank you for your help.

Regards,

Pawel
 
Dear Pawel:

The criteria for one of the filters can be set up like this:

WHERE (YourColumn = [Forms]![FormName]![ControlName]
OR Nz([Forms]![FormName]![ControlName], "") = "")

This will pass all rows when the control is left empty.

Tom Ellison
Microsoft Access MVP
Ellison Enterprises - Your One Stop IT Experts
 
Back
Top