Results 1 to 3 of 3
  1. #1
    ash432012's Avatar
    ash432012 is offline Novice
    Windows XP Access 2007
    Join Date
    Dec 2012
    Location
    Houston, TX
    Posts
    1

    Query - Search for this, not this + that...

    Hello all,



    I hope I can take whatever advice is given to me and execute it!
    I feel like I know a lot about Access as far as how it pertains to what we do here [at work]
    but I don't think I'm very well versed in it overall...

    Anyway, here's my question...
    [btw - I don't know how to run queries using SQL -- I can alter them/take them apart, but not create from scratch...YET! lol..]

    Okay, so ..in the Query design view... I have a table w/a bunch of parts listed... those parts are being edited/paired to dwgs by our 10+ employees --
    I have instructed them that if there is ever anything they are unsure about, to put a comment in a notes field that says "Review"
    As I've been doing QC throughout the project, I've corrected some of these, and others I have added my boss's name so that we can run a query for his name and quickly see what I need him to review...

    Now that we're pretty far into the project, I need to run a query for all the parts that have "Review" in the notes section, but NOT the one's that include my boss's name + review --
    is there anyway to run this query?
    I've tried
    Like "*review*" And <>"*cox*"
    in the criteria row, but the entries w/his name are still coming up..
    This would be a really helpful skill to learn for a lot of other things that I need to QC in our database
    Any assistance you could offer would be greatly appreciated!
    Let me know if there is anything else you need to know to help me with this!

    Thanks guys!
    Ash

  2. #2
    alansidman's Avatar
    alansidman is offline Indifferent
    Windows 7 32bit Access 2010 32bit
    Join Date
    Apr 2010
    Location
    Steamboat Springs
    Posts
    2,536
    Would you upload a copy of the db with some sample data. Make sure that all confidential data has been scrubbed (modified) so that no confidential info is disclosed. Run a compact and repair before you upload.

  3. #3
    ssanfu is offline Master of Nothing
    Windows XP Access 2000
    Join Date
    Sep 2010
    Location
    Anchorage, Alaska, USA
    Posts
    9,664
    Like "*review*" And <>"*cox*"
    Did you try
    Code:
    Like "*review*" And Not Like "*cox*"
    You could try using two queries.
    -- WARNING: this is off the top of my head - not tested ---
    Create the first query and in the criteria row for the comments use
    ]code]Like "*review*"[/code]
    Save it with a name like "qryLikeReview"
    Now create a 2nd query and use the first query "qryLikeReview"
    Add the fields, then in the qriteria row for the comments field, use
    Code:
    Not Like "*cox*"
    The first query gathers all records what has "review" in the comments field and the 2nd query looks for any record that does not have cox in the comments field.

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

Similar Threads

  1. Search Query
    By sgray in forum Queries
    Replies: 7
    Last Post: 02-16-2012, 04:37 AM
  2. Help with search query
    By Sirius in forum Queries
    Replies: 0
    Last Post: 08-08-2011, 03:33 PM
  3. Search Query
    By convey2web in forum Queries
    Replies: 3
    Last Post: 11-08-2010, 02:27 PM
  4. Search with in a Query
    By AccessCodeMonkey in forum Queries
    Replies: 4
    Last Post: 03-09-2010, 03:16 PM
  5. yes/no search query
    By islandboy in forum Queries
    Replies: 7
    Last Post: 06-30-2009, 09:01 AM

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