Results 1 to 3 of 3
  1. #1
    Join Date
    Mar 2009

    Simple Select Query not retrieving results the meet criteria

    Hi Guys

    I have been trying to retreive data from a table that meets the criteria that I have put in but I am getting everything from the table even stuff that does not meet the criteria. The query is below

    SELECT tblPOCommittment.responsibility, tblPOCommittment.authsdDate, tblPOCommittment.supplierNo, tblPOCommittment.preqNumber, tblPOCommittment.preqItemNumber, tblPOCommittment.poNumber, tblPOCommittment.poItemNumber, tblPOCommittment.itemDescription, tblPOCommittment.cmsFacility, tblPOCommittment.cmsCommodity, tblPOCommittment.carNumber, tblPOCommittment.PoQty, tblPOCommittment.PoAmount, tblPOCommittment.packageName, tblPOCommittment.ContractorVendorName, tblPOCommittment.PhaseCode, tblPOCommittment.PaymentType, tblPOCommittment.UnitofMeasure, tblPOCommittment.TermsNotes, tblPOCommittment.RevisionNumber
    FROM tblPOCommittment
    WHERE (((tblPOCommittment.cmsFacility) Is Not Null)) OR (((tblPOCommittment.cmsCommodity) Is Not Null)) OR (((tblPOCommittment.carNumber) Is Not Null)) OR (((tblPOCommittment.cmsFacility) Not Like "N*")) OR (((tblPOCommittment.cmsCommodity) Not Like "N*")) OR (((tblPOCommittment.carNumber) Not Like "N*")) OR (((tblPOCommittment.cmsFacility) Not Like "")) OR (((tblPOCommittment.cmsCommodity) Not Like "")) OR (((tblPOCommittment.carNumber) Not Like ""));

  2. #2
    rommelgenlight is offline Advanced Beginner
    Windows XP Access 2003
    Join Date
    Mar 2009
    can you just attach the database file that you created so I can check it out.

  3. #3
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 10 Access 2013 32bit
    Join Date
    Mar 2007
    8300' in the Colorado Rocky Mountains
    Do it with several queries that each use the previous query. Start trimming down your selection with each query.

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

Similar Threads

  1. Help with a simple query
    By JohnnyO in forum Queries
    Replies: 1
    Last Post: 02-11-2009, 09:43 PM
  2. Select query with two criteria
    By corni in forum Queries
    Replies: 1
    Last Post: 01-22-2009, 05:23 AM
  3. Combine Query Results to One Table
    By pr4t3ek in forum Queries
    Replies: 0
    Last Post: 12-19-2008, 06:37 AM
  4. Entering query results in a form
    By marcello.dolcini in forum Forms
    Replies: 0
    Last Post: 04-15-2007, 06:01 PM
  5. Should be simple Query Question
    By brj1 in forum Queries
    Replies: 2
    Last Post: 03-04-2006, 01:11 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