Neoview SQL Reference Manual (R2.4)

Expressions
An SQL value expression, referred to as an expression, can evaluate to a value with one of these:
Operands can be combined with the concatenation
operator (||). Example: 'HOUSTON,' ||' TEXAS'
“Character Value Expressions” (page 240)
Operands can be combined in specific ways with
arithmetic operators. Example: CURRENT_DATE +
INTERVAL '1' DAY
“Datetime Value Expressions” (page 242)
Operands can be combined in specific ways with addition
and subtraction operators. Example: INTERVAL '2'
YEAR - INTERVAL '3' MONTH
“Interval Value Expressions” (page 246)
Operands can be combined in specific ways with
arithmetic operators. Example: SALARY * 1.10
“Numeric Value Expressions” (page 250)
The data type of an expression is the data type of the value of the expression.
A value expression can be, among other things, a character string literal, a numeric literal, a
dynamic parameter, or a column name that specifies the value of the column in a row of a table.
A value expression can also include functions and scalar subqueries.
Character Value Expressions
The operands of a character value expression—referred to as character primaries—can be
combined with the concatenation operator (||). The data type of a character primary is character
string.
character-expression is:
character-primary
| character-expression || character-primary
character-primary is:
character-string-literal
| column-reference
| character-type-host-variable
| dynamic parameter
| character-value-function
| aggregate-function
| sequence-function
| scalar-subquery
| CASE-expression
| CAST-expression
| (character-expression)
| OLAP-window-function
Character (or string) value expressions are built from operands that can be:
Character string literals
Character string functions
Column references with character values
Dynamic parameters
Aggregate functions, sequence functions, scalar subqueries, CASE expressions, or CAST
expressions that return character values
OLAP window functions
240 SQL Language Elements