Call Level Interface Guide and Reference

SQLSetStmtOption - Set Statement Option

Status of this Function since DB2 CLI Version 5
Note:

In ODBC version 3, SQLSetStmtOption() has been deprecated and replaced with SQLSetStmtAttr(); see SQLSetStmtAttr - Set Options Related to a Statement for more information.

Although this version of DB2 CLI continues to support SQLSetStmtOption(), we recommend that you begin using SQLSetStmtAttr() in your DB2 CLI programs so that they conform to the latest standards.

See DB2 CLI Functions Deprecated for Version 5 for more information on this and other deprecated functions.

Note:This deprecated function cannot be used in a 64-bit environment. For more details see Deprecated Functions Not Supported in a 64-bit Environment.

Migrating to the New Function

The statement:

   SQLSetStmtOption(
              hstmt, 
              SQL_ROWSET_SIZE, 
              RowSetSize);

for example, would be rewritten using the new function as:

   SQLSetStmtAttr(
              hstmt,
              SQL_ATTR_ROW_ARRAY_SIZE,
              (SQLPOINTER) RowSetSize,
              0);


[ Top of Page | Previous Page | Next Page ]