For example if I run the following query, the expression in the WHERE clause will only match on the first letter before a number but is there a way to match on one or more letters first (e.g. in the case where there's a variable number of letters before the number in the field I'm filtering on)?
SELECT FilteredField
FROM Table
WHERE FilteredField LIKE '[a-zA-Z][0-9]'
Example data:
- ABC9
- DEF2
- GH7
- Z1
- XYH2
Essentially I'm looking for the SQL Server 2016 equivalent of the RegEx + when using the LIKE operator.