Results 1 to 2 of 2

Thread: Like Statement?

  1. #1
    Join Date
    May 2006

    Unanswered: Like Statement?

    I am having a problem. I have a column that holds Purchase Order Numbers. The first problem is that I am not the administrator of this database so the PO#'s are in any one of a million variations: PO, P.O., PO#, P.O, etc. The second problem is that other text is entered in this field (dumb, I know but I'm not the administrator) like "POTS, POLYETHELENE, POLYESTER", etc.

    I may be trying to stretch the capabilities of Access but can anyone suggest a statement that could find, in the Left 6 characters, only the characters P, O, ., #, NO or <space>? I've tried several statements using Like but I can only search on a single character? That's ok because it returns all of the PO's but also returns the text such as "POLYESTER", etc.

    Thanks for all of your assistance!


  2. #2
    Join Date
    May 2004
    New York State

    I can't see how to do it with Like, but if you can program in VBA, you can test each character of the string using the Mid() function inside a For...Next loop.

    Hope this helps,


Posting Permissions

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