Database error messages

This guide is for developers who need to understand how OpenText™ Analytics Database's error codes relate to error states returned by the ODBC and JDBC drivers.

This guide is for developers who need to understand how OpenText™ Analytics Database's error codes relate to error states returned by the ODBC and JDBC drivers.

The different ways the database reports errors

The database reports warnings and errors via two different mechanisms: SQLSTATEs and error messages. SQLSTATEs are intended for use by client applications, such as those accessing the database via ODBC or JDBC. Error messages are displayed to interactive users (for example, users connected to the database through vsql) and written to error logs.

About SQLSTATE

The database reports the success or failure of each statement it executes to client applications using a five-character SQLSTATE value. Many of these values are defined by the SQL standard. Others (identified by the letter "V" in their values) are specific to OpenText™ Analytics Database.

SQLSTATE values are grouped into classes which are defined by the first two characters in the SQLSTATE value. The last three characters indicate a specific condition within a class. For example, the SQLSTATE class 22 represents all data errors. The specific SQLSTATE value 22012 represents a division by zero error. SQLSTATE classes let an application that does not recognize a specific SQLSTATE value to still get a general idea of the result.

Warning and error messages

Each error and warning message displayed to interactive users or written to a log file has its own numeric error code assigned to it. For example:

ERROR 3117: Division by zero
WARNING 4098: No projections found
ERROR 5617: Multiple WITH clauses not allowed

The error code number is not related to the SQLSTATE value. However, error and warning messages do correspond to a specific SQLSTATE. They are just a more-specific human-readable message compared to the SQLSTATE, which is mainly intended for client applications.

For example, all warning messages displayed by OpenText™ Analytics Database correspond to the SQLSTATE class 01. The warning message "WARNING 3084: Design Workspace couldn't be dropped" corresponds to the SQLSTATE value 01000 ERRCODE_WARNING.

Error codes do not change between OpenText™ Analytics Database releases, but individual error and warning messages may be added or removed in new releases. Your client application should not depend on particular error code appearing from one release to the next. Instead, it should use the SQLSTATE value to determine the result of executing a statement.

See the SQL state list for all defined SQLSTATE classes and values. This table also links to lists of error or warning messages that are associated with each SQLSTATE value.

In this section