Results 1 to 6 of 6
  1. #1
    aubtiger14 is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Dec 2013
    Posts
    10

    Help with adding criteria


    How do I add criteria for the sales rep number field that will allow me to enter a different sales rep each time the query is run?

  2. #2
    ItsMe's Avatar
    ItsMe is offline Sometimes Helpful
    Windows XP Access 2003
    Join Date
    Aug 2013
    Posts
    7,862
    Double click "sales rep number" in your query builder window and type some criteria in the new criteria field you just created.

  3. #3
    rpeare is offline VIP
    Windows XP Access 2003
    Join Date
    Jul 2011
    Posts
    5,442
    in the criteria of your sales rep number have something like

    [Enter the Sales Rep Number]

    The user will be prompted to enter a number and the query results will be based on whatever's typed in. If you want to look for anything matching a certain string and use wildcards you'd have to have something like


    Like "*" & [Enter the Sales Rep Number] & "*"

    so if you typed in

    A12

    and you had sales rep numbers of

    A12334
    A12345
    A13543

    the query would find the first two and not return the third.

  4. #4
    aubtiger14 is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Dec 2013
    Posts
    10
    More specifically, do i need to enter that as an expression? and if so how do i do that?... i had to enter criterion to find all customers whose names start with the letter C and i entered it in the criterion field as Like "C*"

  5. #5
    aubtiger14 is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Dec 2013
    Posts
    10
    that's what i needed...thanks

  6. #6
    ItsMe's Avatar
    ItsMe is offline Sometimes Helpful
    Windows XP Access 2003
    Join Date
    Aug 2013
    Posts
    7,862
    You can apply criteria at the form or report level too. This way your saved query object's usefulness is not limited to the criteria.

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

Similar Threads

  1. Replies: 1
    Last Post: 08-06-2013, 07:52 PM
  2. Replies: 1
    Last Post: 07-26-2013, 11:30 AM
  3. Replies: 5
    Last Post: 08-02-2012, 09:44 AM
  4. Adding an image if criteria met
    By cjohnston in forum Programming
    Replies: 2
    Last Post: 03-03-2012, 10:27 PM
  5. Replies: 3
    Last Post: 10-25-2011, 11:38 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