Results 1 to 5 of 5
  1. #1
    cap.zadi is offline Competent Performer
    Windows XP Access 2007
    Join Date
    May 2011
    Location
    KSA
    Posts
    481

    Query Parameter!


    Dears,

    I am looking to apply a Parameter in my Query in the field "ShiftID" where 1 = Day Shift & 2 = Night Shift.

    so i fill up the criteria with [Which Shift?] and it returns the results for the required shift.

    what case can be if some times we want to see the results for both together?

    Please advise?

    zee

  2. #2
    goodguy is offline Competent Performer
    Windows Vista Access 2007
    Join Date
    Dec 2010
    Location
    Zanzibar, Tanzania
    Posts
    228
    Make another query with criteria SHIFT = 1 OR SHIFT = 2.

  3. #3
    cap.zadi is offline Competent Performer
    Windows XP Access 2007
    Join Date
    May 2011
    Location
    KSA
    Posts
    481
    Sir, i am expecting in same query like if it works?

    If put the value for 1/2 or just leave it empty and click so both shifts appear.

    is the condition like;

    [Which Shift?] OR "Both''

    plz advise.

  4. #4
    alansidman's Avatar
    alansidman is offline Indifferent
    Windows 7 32bit Access 2007
    Join Date
    Apr 2010
    Location
    Steamboat Springs
    Posts
    2,536
    Change your criteria to Like [Which Shift?] & "*"

    If you leave the parameter empty when it appears then you will get all records. If you put in 1 then you will get only shift 1 and if you put in 2 you will only get shift 2 records.

    Alan

  5. #5
    cap.zadi is offline Competent Performer
    Windows XP Access 2007
    Join Date
    May 2011
    Location
    KSA
    Posts
    481
    thanks for u kindness
    it is done

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

Similar Threads

  1. How to run parameter query from VBA
    By John Southern in forum Programming
    Replies: 10
    Last Post: 02-07-2014, 02:24 PM
  2. Parameter Query....
    By Casper2012 in forum Queries
    Replies: 5
    Last Post: 08-16-2011, 11:06 AM
  3. Parameter Query?
    By luckysarea in forum Queries
    Replies: 3
    Last Post: 04-22-2011, 12:57 PM
  4. Parameter query
    By doss13 in forum Queries
    Replies: 1
    Last Post: 06-26-2010, 06:11 AM
  5. Parameter Query help...
    By daggy in forum Queries
    Replies: 1
    Last Post: 05-11-2010, 01:10 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