Results 1 to 3 of 3
  1. #1
    Keats713 is offline Novice
    Windows XP Access 2010 64bit
    Join Date
    Dec 2016
    Posts
    1

    How To Use Wildcard Characters in Query Search

    I have a table full of thousands of results for the past few years. I created a query that requires the input of a Product ID (4-6 numbers) and a Code Date (formatted ###-#). The code date is in julian date format, so the code date corresponding to January 1st, 2016 would be 001-6.

    I need to query the table and pull all results from 2016 for any product.
    Product ID - Anything
    Code Date - (###-6) <-- The first 3 digits can be any number, but the number after the hyphen has to be 6.



    I can't seem to figure out how to use the wildcard characters correctly in the query inputs to pull the data that I need. And I do not have time to go through all of the records to find all code dates ending in 6. Can someone help me figure out how to pull what I need?

  2. #2
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,524
    Select * from table Where [codeDate] like "*-6"

  3. #3
    CJ_London is online now VIP
    Windows 10 Access 2010 32bit
    Join Date
    Mar 2015
    Posts
    11,412
    Appreciate you may not have any at the moment, but assuming your app has some longevity - what happens with dates in 2006 or 2026?

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

Similar Threads

  1. Replies: 9
    Last Post: 12-05-2013, 11:48 AM
  2. Search on text fields - Wildcard?
    By Harley Guy in forum Queries
    Replies: 3
    Last Post: 08-13-2013, 11:07 AM
  3. Wildcard search within ComboBox to control RowSource
    By CaptainKen in forum Programming
    Replies: 22
    Last Post: 05-16-2012, 02:19 PM
  4. Cant see where its wrong - VBA wildcard search.
    By shabbaranks in forum Programming
    Replies: 3
    Last Post: 03-22-2012, 03:56 AM
  5. Wildcard Expressions in Search Field
    By eww in forum Programming
    Replies: 4
    Last Post: 09-29-2010, 10:27 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