Ever need to find a value in a column where it’s LIKE something? T-SQL provides functionality with the following wildcard characters:
% – Any string of zero or more characters; WHERE word LIKE ‘JOHN%‘ returns John or Johnathan.
_ (underscore) – Any single character; WHERE word LIKE ‘_an’ returns Dan, Tan, or Fan.
[] – Any character within specified range or set; WHERE word LIKE ‘T[AE]N’ returns Tan and Ten.
[^] – Any single character not in specified range or set; WHERE word LIKE ‘T[^AE]N’ return Tin, Ton,
Percent Wildcard ( % )
Underscore Wildcard ( _ )
Bracket Wildcard ( [] )
Not-Bracket Wildcard ( [^] )
Happy Coding!