Is it possible to use LIKE in a SQL query to look for patterns of numbers and letters. I need to locate all records where the specific field data has the pattern (2 Numbers,1 hyphen, 3 Letters) ## – AAA I am using SSMS with SQL Server 2008. Any help would be appreciated. THANKS.
Share
I think
LIKE '%[0-9][0-9]-[A-Z][A-Z][A-Z]%'should work.I’m not sure of your case sensitivity requirements but you can stick a COLLATE in as below.