- Reference manual
- SWI-Prolog ODBC Interface
ODBC operations return success, error or `success with info'. This section explains how results from the ODBC layer are reported to Prolog.
If an ODBC operation returns `with info', the info is extracted from
the interface and handled to the Prolog message dispatcher print_message/2.
The level of the message is
informational and the term is
of the form:
- odbc(State, Native, Message)
- Here, State is the SQL-state as defined in the ODBC API, Native is the (integer) error code of the underlying data source and Message is a human readable explanation of the message.
If an ODBC operation signals an error, it throws the exception
arguments of the
odbc(State, Native, Message), _)
odbc/3 term are explained in section
In addition, the Prolog layer performs the normal tests for proper arguments and state, signaling the conventional instantiation, type, domain and resource exceptions.