Hi everyone,
I have this problem, I'm creating a form where the user could fill some or all the fields. those fields would be use to run a query. My problems is I don't know how to do it with out writing a query for each combination that users can use: Eg:
the form has:
Code1 Color1
or Code2 Color2
or Code3 Color3
City or Zip
Date between Date1 and Date2
So the user could enter a Code1 and a color1 and that is it. and my query would only use those fields. But is they choose to enter Code1, color1 and Code2 and Color2 and City. then I need to run a query with those fields. But you see I would have to create a query for each combination...YIKESS I know there is a better way.
So I thought on the query to write a IIF(IsNull(field),Like "*",(field)) But of course did not work.
Does anyone have a solution for my problem.. am I way off.!
Appreciate you taking the time to read this and any help would be greatly appreciated.
Thanks
AMD2800
I have this problem, I'm creating a form where the user could fill some or all the fields. those fields would be use to run a query. My problems is I don't know how to do it with out writing a query for each combination that users can use: Eg:
the form has:
Code1 Color1
or Code2 Color2
or Code3 Color3
City or Zip
Date between Date1 and Date2
So the user could enter a Code1 and a color1 and that is it. and my query would only use those fields. But is they choose to enter Code1, color1 and Code2 and Color2 and City. then I need to run a query with those fields. But you see I would have to create a query for each combination...YIKESS I know there is a better way.
So I thought on the query to write a IIF(IsNull(field),Like "*",(field)) But of course did not work.
Does anyone have a solution for my problem.. am I way off.!
Appreciate you taking the time to read this and any help would be greatly appreciated.
Thanks
AMD2800