Results 1 to 2 of 2
  1. #1
    achammar is offline Advanced Beginner
    Windows 7 64bit Access 2007
    Join Date
    Jul 2019
    Posts
    48

    Set criteria in query to not have any criteria so all records show using value in combo box

    Hi all,



    So I have a very simple query. The criteria of one of the fields is set to be equal to the value of a combo box on a form. It works fine. It only shows the records of whatever is equal to the value in that combo box. My problem is how do I show all the records in case I don't want a criteria. I can't get it to do that. I choose a value in the combo box, then click a button that runs the query. But I haven't figured out how to make the query show all records if I don't want any criteria in that field.

    This is the criteria I have in the query in 1 field:
    [Forms]![frmSheetPlate]![cboSheetPlate]

    Thank you so much for any help!

  2. #2
    CJ_London is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    Mar 2015
    Posts
    11,430
    just remove the criteria.

    or perhaps

    [Forms]![frmSheetPlate]![cboSheetPlate] OR [Forms]![frmSheetPlate]![cboSheetPlate] is null



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

Similar Threads

  1. Show records with criteria - query
    By Lukael in forum Access
    Replies: 2
    Last Post: 01-22-2016, 03:56 AM
  2. Only show records that meet criteria
    By RussH in forum Reports
    Replies: 9
    Last Post: 04-10-2013, 05:25 AM
  3. Replies: 5
    Last Post: 10-12-2012, 11:00 AM
  4. Replies: 2
    Last Post: 07-31-2011, 04:03 AM
  5. Replies: 1
    Last Post: 06-12-2011, 07:08 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