Returns current connection settings for an application
process. The sqle_conn_setting data structure is populated with the
connection setting types and values.
API include file
sqlenv.h
API and data structure syntax
SQL_API_RC SQL_API_FN
sqleqryc (
struct sqle_conn_setting * pConnectionSettings,
unsigned short NumSettings,
struct sqlca * pSqlca);
SQL_API_RC SQL_API_FN
sqlgqryc (
struct sqle_conn_setting * pConnectionSettings,
unsigned short NumSettings,
struct sqlca * pSqlca);
sqleqryc API parameters
- pConnectionSettings
- Input/Output. A pointer to an sqle_conn_setting structure, which
specifies connection setting types and values. The user defines an
array of NumSettings connection settings structures, and sets the
type field of each element in this array to indicate one of the five
possible connection settings options. Upon return, the value field
of each element contains the current setting of the option specified.
- NumSettings
- Input. Any integer (from 0 to 7) representing the number of connection
option values to be returned.
- pSqlca
- Output. A pointer to the sqlca structure.
Usage notes
The connection settings for
an application process can be queried at any time during execution.
If
QUERY CLIENT is successful, the fields in the sqle_conn_setting structure
will contain the current connection settings of the application process.
If SET CLIENT has never been called, the settings will contain the
values of the precompile options only if an SQL statement has already
been processed; otherwise, they will contain the default values for
the precompile options.
REXX API syntax
QUERY CLIENT INTO :output
REXX API parameters
- output
- A compound REXX host variable containing information about the
current connection settings of the application process. In the following,
XXX represents the host variable name.
- XXX.1
- Current connection
setting for the CONNECTION type
- XXX.2
- Current connection
setting for the SQLRULES
- XXX.3
- Current connection
setting indicating which connections will be released when a COMMIT
is issued.
- XXX.4
- Current connection
setting of the SYNCPOINT option. The SYNCPOINT option is ignored and
is available only for backward compatibility. Indicates whether a
transaction manager should be used to enforce two-phase commit semantics,
whether the database manager should ensure that there is only one
database being updated when multiple databases are accessed within
a single transaction, or whether neither of these options is to be
used.
- XXX.6
- Current connection
setting for deferred PREPARE.