How to escape a single quote in SQL Server?
- How-Tos FAQs
- February 1, 2019

The most simple way to escape a single quote in SQL Server is to pair it with another single quote.
Below are some examples:
-- For selecting: [My name's Jack.]
SELECT 'My name''s Jack.' escaping_quote
-- Output
escaping_quote
--------------------
My name's Jack.
-- For selecting: ['My name's Jack.']
SELECT '''My name''s Jack.''' escaping_quote
-- Output
escaping_quote
-------------------
'My name's Jack.'
Up Next:
Read How to get only the DATE part from the DATETIME in SQL Server