Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Query Problem Again...

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
Thanks for the tip but it still doesn't work. If I use the And command the user has to enter all data. What I want them to be able to do is enter as much or as little information as they want. So if all they want to enter is the filenumber then they can...or if all they want to do is insert the Incident Type it will pull up all records. So is there a way to let the user enter as little or as much information as they wish? Thanks
 
First, try to respond to your initial post. Anyone seeing this is going to be lost.

You still want to use the AND's. What you need to do now is to build your query string, checking to see if a value is in the text box. You can do this using the IIF and the ISNULL functions. Something like:

IIF(MyField1 NOT ISNULL, AddToWhereClause, Don'tAddToWhereClause)

I am not sure on the actual syntax, but you should be able to use the help to get you there. If not, post back and we can see what we can do... Terry M. Hoey
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top