select where column with a % How can I select all records with a % in? I think this code doesn't work.

SELECT column1, column2 FROM table WHERE column1 LIKE '%%%'



first and last % for zero, one or more chars
second % for the percent skinn


Can anyone suggest me how it can work? I use MS-SQL server.

Thanks in advance
For special characters (% and _), you need to escape them:

WHERE column LIKE '%[%]%';


or

WHERE column LIKE '%\%%' ESCAPE '\';


This is covered in the documentation for LIKE, in the sections "Using Wildcard Characters as Literals" and "Pattern Matching with the ESCAPE Clause." Your first stop should always be the official documentation.