All character, text, date, and time data must be enclosed in single or double quotes when you enter it as a literal. Use single quotes if the quoted_identifier option of the set command is set on. If you use double quotes, Adaptive Server treats the text as an identifier.
Character literals may be any length, whatever the logical page size of the database. If the literal is wider than 16KB (16384 bytes), Adaptive Server treats it as text data, which has restrictive rules regarding implicit and explicit conversion to other datatypes. See Chapter 1, “System and User-Defined Datatypes,” in the Reference Manual: Building Blocks for a discussion of the different behavior of character and text datatypes.
When you insert character data into a char, nchar, unichar, univarchar, varchar, or nvarchar column for which the specified length is less than the length of the data, the entry is truncated. Set the string_rtruncation option on to receive a warning message when this occurs.
This truncation rule applies to all character data, whether it resides in a column, a variable, or a literal string.
There are two ways to specify literal quotes within a character entry:
Use two quotes. For example, if you begin a character entry with a single quote and you want to include a single quote as part of the entry, use two single quotes: 'I don’t 'understand.' ' For double quotes: “He said, “ “It’s not really confusing.” ”
Enclose the quoted material in the opposite kind of quotation mark. In other words, surround an entry containing a double quote with single quotes, or vice versa. For example: “George said, 'There must be a better way.'”
To enter a character string that is longer than the width of your screen, enter a backslash (\) before going to the next line.
Use the like keyword and wildcard characters described in Chapter 2, “Queries: Selecting Data from a Table,” to search for character, text, and datetime data.
See Chapter 1, “System and User-Defined Datatypes,” in the Reference Manual: Building Blocks for details on inserting text data and information about trailing blanks in character data.