Text literals are strings enclosed in single quotes (') and are used to specify string values in expressions, conditions, SQL functions, and SQL statements.
Text literals have the properties of the CHAR and VARCHAR2 data types.
In expressions and conditions, OceanBase Database treats text literals as the CHAR data type. If the lengths of two values are different, the shorter value is padded with spaces at the end to match the length of the longer value before comparison.
When specifying text literals, the maximum length of a CHAR value is 2000, and the maximum length of a VARCHAR2 value is 32767.
Here are some valid text literals. To represent a single quote within a string, you need to insert an additional single quote before the single quote in the string:
'Jackie''s raincoat'
'Hello'
'09-MAR-98'
'Today is a nice day'