NonStop SQL/MP Reference Manual

Table Of Contents
NonStop SQL/MP Reference Manual142115
C-12
Character Expressions
A character expression consists of one or more operands connected by string operators,
as shown in the following diagram.
string-literal
represents a series of characters and consists of that series of characters surrounded
by double or single quotation marks, optionally preceded by a clause that specifies
the character set associated with the characters. For a full description of string
literals, see String Literals on page S-78.
column-name
is the valid name of a column in a table, optionally qualified by a collation name.
The column name must refer to a column with a character data type.
parameter-name
is a parameter of a character data type, optionally associated with a collation.
host-variable-name
is the name of a host variable that contains a value with a character data type.
string-function-invocation
is a call to a function such as UPSHIFT, TRIM, or SUBSTRING that returns a string
as a result.
concatenation-operator
specifies the following operator:
||
The concatenation operator concatenates two string operands and produces a string
as a result. If either of the character strings has a VARCHAR data type, the result
has a VARCHAR data type. If both character strings are fixed CHAR strings, the
result is a fixed CHAR. Operands should have identical character sets.
string-operand [ [ string-operator
string-operand ] ... ]
string-operand is:
{ string-literal }
{ column-name }
{ parameter-name }
{ host-variable-name }
{ string-function-invocation }
string-operator is:
{ concatenation-operator }