xcall SQL, SQLOP_PST_FREE, cmdhdr
The SQLOP_PST_FREE function frees all resources associated with a previously prepared statement, and should be called for each prepared statement that is no longer needed. However, it is not necessary to explicitly free statements just prior to disconnecting (see SQLOP_DISCONNECT), since that will automatically free all statement resources associated with the connection.
Parameters
cmdhdr (ST_SQL_CMDHDR), [in/out]
The fields of interest to this opcode in the cmdhdr structure (defined in SQL.DEF) are listed below.
Field |
Dir |
Notes |
---|---|---|
handle |
in |
handle to connection (returned from SQLOP_INIT_CONN) |
dbmsconid |
in |
|
opflags |
n/a |
|
cmdarg1 |
n/a |
|
cmdarg2 |
n/a |
|
rc |
out |
return code (0 = ok, see SQLERR_xxx) |
rcext |
out |
extended error code |
info1 |
n/a |
|
info2 |
n/a |
|
sqlstate |
out |
ANSI standard SQL state code |
reshdl |
n/a |
|
psthdl |
in |
Must match the value returned from the corresponding SQLOP_PST_PREPARE and SQLOP_STMT_EXECUTE statements |