sql where char in sring code example Example: locate sql server SELECT CHARINDEX('b','ab') //returns 2