Can I query two itmes in the same record field?

  • Thread starter Thread starter Dave
  • Start date Start date
D

Dave

I have used Database Wizard to successfully make queries. All is well here.

I would like to know if I can enter 2 items on the search line for the same
field and get results.

Example; the name product contains, Apples, Oranges, Pears, and Bananas.

If I enter Apples, results are as expected. Can I enter Apples and Oranges
somehow and get an "either" or an "and" return.

So the results would be returns for all of the Apples or all of the Oranges
or both.

Thanks

Dave
 
Yes. Create a form that contains three elements:

o A text box named fruit1.
o A text box named fruit2.
o A Submit button.

Configure the form properties to use a custom form
handler, but don't specify an Action property. This makes
the form submit to the same page.

In the DRW, advance to page 3, then click More Options,
Criteria, and Add. Then enter:

Field Name prodname
Comparison Contains
Value fruit1
Use This Search Form Field: Checked
And/Or Or

Next, click OK, click Add, and enter:

Field Name prodname
Comparison Contains
Value fruit2
Use This Search Form Field: Checked
And/Or And

Jim Buyens
MicrJim Buyens
Microsoft FrontPage MVP
http://www.interlacken.com
Author of:
*----------------------------------------------------
|\---------------------------------------------------
|| Microsoft Office FrontPage 2003 Inside Out
||---------------------------------------------------
|| Web Database Development Step by Step .NET Edition
|| Microsoft FrontPage Version 2002 Inside Out
|| Faster Smarter Beginning Programming
|| (All from Microsoft Press)
|/---------------------------------------------------
*----------------------------------------------------
osoft FrontPage MVP
http://www.interlacken.com
Author of:
*----------------------------------------------------
|\---------------------------------------------------
|| Microsoft Office FrontPage 2003 Inside Out
||---------------------------------------------------
|| Web Database Development Step by Step .NET Edition
|| Microsoft FrontPage Version 2002 Inside Out
|| Faster Smarter Beginning Programming
|| (All from Microsoft Press)
|/---------------------------------------------------
*----------------------------------------------------
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top