Call Level Interface Guide and Reference

Appendix D. Extended Scalar Functions

The following functions are defined by ODBC using vendor escape clauses. Each function may be called using the escape clause syntax, or calling the equivalent DB2 function.

These functions are presented in the following categories:

For more information about vendor escape clauses, refer to ODBC Scalar Functions.

The tables in the following sections indicates for which servers (and the earliest versions) that the function can be accessed, when called from an application using DB2 CLI Version 2.1.

All errors detected by the following functions, when connected to a DB2 Version 2 server, will return SQLSTATE 38552. The text portion of the message is of the form SYSFUN:nn where nn is one of the following reason codes:

01
Numeric value out of range
02
Division by zero
03
Arithmetic overflow or underflow
04
Invalid date format
05
Invalid time format
06
Invalid timestamp format
07
Invalid character representation of a timestamp duration
08
Invalid interval type (must be one of 1, 2, 4, 8, 16, 32, 64, 128, 256)
09
String too long
10
Length or position in string function out of range
11
Invalid character representation of a floating point number


[ Top of Page | Previous Page | Next Page ]