GET DIAGNOSTICS statement

Use the GET DIAGNOSTICS statement to return diagnostic information about the most recently executed SQL statement.

Syntax

(explicit id gdi001) gdi001 (explicit id gdi002) gdi002 GET DIAGNOSTICS { <Statement Clause>[] | <EXCEPTION Clause>[] }

Usage

Use this statement with Informix® ESQL/C.

The GET DIAGNOSTICS statement retrieves specified status information that the database server records in a structure called the diagnostics area. Using GET DIAGNOSTICS does not change the contents of the diagnostics area.

The GET DIAGNOSTICS statement uses one of the following two clauses:
  • The Statement clause returns count and overflow information about errors and warnings that the most recent SQL statement generates.
  • The EXCEPTION clause provides specific information about errors and warnings that the most recent SQL statement generates.