Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to make this sql query? 2

Status
Not open for further replies.

7Star

Technical User
Nov 17, 2005
13
SE
Hi,

I was wondering if anyone could help me do the following query in sql:

In my database I have a column, PNR, that stores values in the with the format XXXXX-XXXX, where X can be either a numerical value or a letter. The data I want to get from the column PNR is records that does have one or more letter. For example if I have the following records:

247883-1111
324233-2331
123213-2344
71020B-4995

Then I just want the 71020B-4995 record. Anyone have some ideas howto make a query like this?
/ Ola

 
Code:
select ...
from myTable
where myColumn [!]like '%[A-Z]%'[/!]

------
Theory: everybody knows everything, nothing works
Practice: everything works, nobody knows why

[banghead]
 
Oh, it wasnt harder than that? :)
Thanks a lot, both of you
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top