Results 1 to 6 of 6
  1. #1
    dannybeaver is offline Novice
    Windows 7 32bit Access 2003
    Join Date
    Aug 2014
    Posts
    19

    Text Box Only Finding Records with Exact Text

    Hi there,

    I have a text box on my main form, that filters records on a subform, where its record source is a query.

    The text box works okay for filtering, however it is not doing something that I would like it to.

    Say we have these records

    TM STEELS
    TM Steels



    If I was to type in STEELS, then only the top record would be displayed, likewise, if I typed in Steels, only the bottom would be displayed.

    What I would like, is if you were to type steels, for example, both of the records would be displayed.

    In the criteria of the field this is based on, in the query, I have:

    Code:
    Like "*" & [Forms]![MainWindow].[NameTxt] & "*"
    As I say, this works for bringing in results that EXACTLY match the text entered in the text box, but I want it to work as explained above.

    If you need any more information, please do not hesitate to ask.

    Thanks everyone! D

  2. #2
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,549
    Access does not recognize case. So, STEEL = stEEl.

  3. #3
    dannybeaver is offline Novice
    Windows 7 32bit Access 2003
    Join Date
    Aug 2014
    Posts
    19
    hi,
    thanks for the response.

    If that is true, why is then that when I enter Steels, on the TM Steels record is shown, and not the TM STEELS one.

    Surely if it did not recognise case, then it would return both records no?

    Thanks again for the reply.

  4. #4
    orange's Avatar
    orange is online now Moderator
    Windows XP Access 2003
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,850
    Please post a copy of your database. Access does not recognize case unless specifically instructed/programmed to do so.

  5. #5
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,649
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  6. #6
    dannybeaver is offline Novice
    Windows 7 32bit Access 2003
    Join Date
    Aug 2014
    Posts
    19
    this issue is related to an sql problem, where the database has case sensitive set against it in the Collation property.

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

Similar Threads

  1. Replies: 3
    Last Post: 02-22-2013, 11:34 PM
  2. Replies: 3
    Last Post: 02-07-2013, 09:53 PM
  3. Replies: 11
    Last Post: 10-12-2012, 08:37 AM
  4. Replies: 1
    Last Post: 05-24-2012, 04:59 AM
  5. Finding highest value in a text field
    By cdominguez in forum Queries
    Replies: 3
    Last Post: 06-02-2009, 09:39 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