A value expression returns a value that can be a string, a number, or a null value. Arithmetic Operators describes the operators used in arithmetic expressions. Table 5-2 Arithmetic Operators Symbol Function + Addition - Subtraction * Multiplication / Division Statistical Operators describes the operators used in statistical expressions. Table 5-3 Statistical Operators Function Value of Function AVERAGE The average of the values specified by the value expression for all records specified by the RSE. The value expression must be a numeric data type. COUNT The number of records in the stream specified by the RSE. MAX The largest of the values specified by the value expression for all records specified by the RSE. MIN The smallest of the values specified by the value expression for all records specified by the RSE. TOTAL The sum of the values specified by the value expression for all records specified by the RSE. The value expression must be a numeric data type. Built-in Function Description describes the built-in function names and values. See the Oracle Rdb7 SQL Reference Manual for more details on the use and restrictions for using SQL built-in functions. Table 5-4 Built-in Function Description Name Description NULL Specifies a null value. TRIM Removes leading or trailing characters from any character value expression. Note: The CHARACTER keyword is required in CDO. POSITION Searches for a string in a character value expression. USER Specifies the user name of the current process. CURRENT_USER Returns the current active user name for a request. CURRENT_DATE Returns a DATE data type value containing year, month, and day for today's date. CURRENT_TIME Returns a TIME data type value containing hours, minutes, and seconds for the current time. You can specify a fractional precision between 0 and 2 for the seconds returned by CURRENT_TIME. The fractional seconds precision is a number that designates the number of digits returned in the field. The fractional precision is the negative of the value specified in the SCALE clause. The CURRENT_TIME keyword and the left parenthesis for the fractional precision must be separated by a space. Otherwise, CDO interprets it as the name of an element with a version of the value specified in the fractional precision. CURRENT_ Returns a TIMESTAMP data type value containing TIMESTAMP year, month, and day for today's date and hours, minutes, and seconds for the current time. You can specify a fractional precision between 0 and 2 for the seconds returned by CURRENT_TIMESTAMP. The fractional seconds precision is a number that designates the number of digits returned in the field. The fractional precision is the negative of the value specified in the SCALE clause. The CURRENT_TIMESTAMP keyword and the left parenthesis for the fractional precision must be separated by a space. Otherwise, CDO interprets it as the name of an element with a version of the value specified in the fractional precision. CHARACTER_ Calculates the length of a value expression of LENGTH any data type. You can use CHAR_LENGTH as an alternative for CHARACTER_LENGTH. OCTET_LENGTH Calculates the length, in octets, of a value expression of any data type. UPPER Converts all lowercase characters in a value expression to uppercase characters. LOWER Converts all uppercase characters in a value expression to lowercase characters. SESSION_USER Returns the current active session user name. SUBSTRING Returns portions of character value expressions. SYSTEM_USER Returns the user name of the login process at the time of the database attachment. CAST Converts a value expression to another data type. EXTRACT Returns a single date-time field expressed as an integer from a field defined with a data type of DATE, TIME, TIMESTAMP, or INTERVAL. TRANSLATE Translates a character value expression from one character set to another compatible character set, such as RDB$KANJI to Kanji.