Results 1 to 3 of 3
  1. #1
    Join Date
    Aug 2008
    Posts
    1

    Unanswered: Access Query Using User-Specified Criteria

    Hello,

    I need to create a query/report in Access 97 that will return all records containing any part of the text entered by the user.

    For example:

    I have a field containing graphic codes for artwork. The codes are made up of letters and numbers--the letters representing team name and the numbers representing design series (ex. IND1517). I need a search that will allow users to enter any part of the graphic code and return all records containing that user-entered data. I have tried things such as >=[Enter Graphic], but this returns everything listed after their entry. It also does not allow the users to search by the series number (i.e. the 1517 part).

    Can anyone help to point me in the right direction?

    Thanks,
    Dan

    (p.s. Please go easy on me...this is my first post

  2. #2
    Join Date
    Sep 2006
    Location
    Surrey, UK
    Posts
    995
    Provided Answers: 2
    The statement that you need is
    Code:
    LIKE "%" & [Enter Graphic] & "%"
    Or possibly replace the percent signs with asterisks - I've spent more time with SQL than Access lately.

  3. #3
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    Definitely replace the %'s with *'s.
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •