Results 1 to 2 of 2
  1. #1
    Gary Childress is offline Advanced Beginner
    Windows 7 64bit Access 2010 64bit
    Join Date
    Dec 2012
    Posts
    34

    Question Regarding Searching a Table for Multiple Criteria

    Not sure how to word this but Is there a way to search a table for all the records which contain more than one criteria in a particular field?

    I have attached a sample database below. It contains one form, one table and two queries. The form has a single field on it where I can choose the criteria for one of the queries. In the sample database let's say I wanted to query all companies which were located in both Miami and Richmond. I want to be able to set that criteria on the query form. But I'm not sure how to do it. As it stands now I can set the criteria as Miami or I can set it as Richmond or some other city. However, I can't set the criteria to BOTH Miami and Richmond or more than one city. Is there a way to do that?

    In other words, suppose I wanted to find some arbitrary combination of cities in my table and pull up all the records which contain those cities. How would I set up a search criteria field on a form to do that?



    I hope that makes sense. Thanks.



    Click image for larger version. 

Name:	1.png 
Views:	8 
Size:	19.5 KB 
ID:	23135Click image for larger version. 

Name:	2.png 
Views:	8 
Size:	11.8 KB 
ID:	23136Database1.zip

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,930
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 6
    Last Post: 07-27-2015, 10:23 AM
  2. Searching multiple fields in a table
    By KyleMac in forum Programming
    Replies: 2
    Last Post: 12-11-2014, 02:20 PM
  3. Searching Question
    By Jbelle7435 in forum Programming
    Replies: 5
    Last Post: 05-15-2011, 07:48 AM
  4. Replies: 1
    Last Post: 02-18-2011, 01:40 AM
  5. Replies: 2
    Last Post: 05-25-2010, 02:45 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums