SQLCancel - Cancel statement
SQLCancel()
is used
to end the processing of an SQL statement operation that is running
synchronously. To cancel the function, the application calls SQLCancel()
with
the same statement handle that is used by the target function, but
on a different thread. How the function is canceled depends on the
operating system.
Syntax
SQLRETURN SQLCancel (SQLHSTMT hstmt);
Function arguments
Data type | Argument | Use | Description |
---|---|---|---|
SQLHSTMT | hstmt | Input | Statement handle |
Usage
A successful return code indicates that the implementation has accepted the cancel request; it does not ensure that the processing is canceled.
Return codes
- SQL_SUCCESS
- SQL_INVALID_HANDLE
- SQL_ERROR
Diagnostics
SQLSTATE | Description | Explanation |
---|---|---|
HY009 * | Argument value that is not valid | hstmt is not a statement handle. |
Restrictions
Db2® for i CLI does not support asynchronous statement processing.