Was this helpful?
SQLSTATE Variable Usage
You can use the SQLSTATE variable in an ESQL/BASIC program to return status information about the last SQL statement that was executed. SQLSTATE must be declared in a declaration section. Also, it is valid across all sessions, so you only need to declare one SQLSTATE per application.
To declare this variable, use:
character5 SQLSTATE
or:
character5 SQLSTA
Last modified date: 08/28/2024