There are two ways to specify literal quotes within a char or varchar entry. The first method is to use an additional quote with a quote of the same type. This is called “escaping” the quote. For example, if you begin a character entry with a single quote, but you want to include a single quote as part of the entry, use two single quotes:
’I don’’t understand.’
Here is an example containing internal double and single quotes. The single quote does not have to be escaped, but the double quote does:
"He said, ""It’s not really confusing."""
The second method is to enclose a quote in the opposite kind of quotation mark. In other words, surround an entry containing a double quote with single quotes (or vice versa). Here are some examples:
’George said, "There must be a better way."’ "Isn’t there a better way?" ’George asked, "Isn”t there a better way?"’
To continue a character string that would go off the end of one line on your screen, enter a backslash (\) before going to the following line.
If the quoted_identifier option is set to on, do not use double quotes around character or date data. You must use single quotes, or Adaptive Server treats the data as an identifier. For more information about quoted identifiers, see “Delimited identifiers”.