If this is your first visit, be sure to check out the FAQ by clicking the link above.
You may have to register before you can post: click the register link above to proceed.
To start viewing messages, select the forum that you want to visit from the selection below.
Is it possible to search just numeric characters in a string using wildcards?
Example:
I want to find Clients with Code of 60111, 61234, etc. The field is varchar but the sequence I want is always 5 numerics starting with '6' (6####). However, there are also codes such as 6123A or 6055G, which I do not want included in my results.
When searching on
"ClientCode like '6%'"
or
"ClientCode like '6____'"
I get the codes included I do not want.
I know in Access I can search for just numeric values (ClientCode like '6####'). I've tried that in MySQL with no success so far. Is this possible?
To be honest with you, I have never tried this. But right off the top of my head, what I would do is say left(field,5) > 60000, since if you get back, 6111A, it would be less than 60000.