|
|
String Pseudo-Literals
The following sections document string pseudo-literals.
CURRENT_USER
Returns the name of the currently connected USER or OS_USER ident or the PROGRAM ident that is currently entered.When used in a routine or trigger, it returns the name of the creator of the schema to which the routine or trigger belongs.Syntax
Syntax for the CURRENT_USER function:
Rule
- When used in a routine or trigger, the result is the name of the creator of the schema to which the routine or trigger belongs, otherwise the value is the name of the connected ident or the program that was entered
Example
CREATE DOMAIN NAME AS CHAR(128) DEFAULT CURRENT_USER;SESSION_USER
Returns the name of the currently connected ident.Syntax
Syntax for the SESSION_USER function:
Rule
- The result is the name of the current ident (i.e. the ident who established the current database connection).
Example
The following example returns the Program ident if entered, otherwise the session ident:
SET CHR_STR = COALESCE(CURRENT_PROGRAM(), SESSION_USER);USER
Standard Compliance
This section summarizes standard compliance for scalar functions.
|
Upright Database Technology AB Voice: +46 18 780 92 00 Fax: +46 18 780 92 40 dbtechnology@upright.se |
|
|