>SELECT CAST(LEFT(Number, PATINDEX('%[-,A-Z]%', Number + 'A')-1) AS int), Number FROM occ_main > WHERE CAST(LEFT(Number, PATINDEX('%[-,/\@#$%^!&*()+A-Z]%', Number + 'A')-1) AS int) BETWEEN 302 AND 390 >>I updated number in the table so that a few records contained the value of 311-3B or 308A in the number field and when I ran the above query it returned them as well as 302-309 plain values.
>(no column name) number >302 302 >308 308A >311 311 >311 311-3B >312 312 >308 308 >>Etc which is correct.