Connection string keywords - other properties

Use these iSeries™ Access ODBC driver connection string keywords to change other properties of the ODBC connection.

The following table lists other connection string keywords that are recognized by the iSeries Access ODBC driver:

Table 1. iSeries Access ODBC connection string keywords for other properties
Keyword Description Choices Default
ALLOWPROCCALLS Specifies whether stored procedures can be called when the connection attribute, SQL_ATTR_ACCESS_MODE, is set to SQL_MODE_READ_ONLY. 0 = Do not allow stored procedures to be called

1 = Allow stored procedures to be called

0
DB2SQLSTATES Specifies whether or not to return ODBC-defined SQL States or DB2® SQL States. Refer to the DB2 UDB SQL Reference for more details on the DB2 SQL States. This option should be used only if you have the ability to change the ODBC application's source code. If not, you should leave this option set to 0 as most applications are coded only to handle the ODBC-defined SQL States. 0 = Return ODBC-defined SQLStates

1 = Return DB2 SQL States

0
Start of changeDATETIMETOCHAR or ConvertDateTimeToCharEnd of change Start of change Specifies one or more options on how date, time, and timestamp data types are reported to an application. To specify multiple options add together the values for the options. This option supports cases in which date values such as 24:00:00 are used. End of change Start of changeTo determine the value for this keyword, add the values below that are associated with each option that you want.

0 = Continue to map the DATE, TIME, and TIMESTAMP data types as SQL_TYPE_DATE, SQL_TYPE_TIME, and SQL_TYPE_TIMESTAMP

1 = Return DATE data type as SQL_CHAR

2 = Return TIME data type as SQL_CHAR

4 = Return TIMESTAMP data type as SQL_CHAR

End of change
Start of change0End of change
DBCSNoTruncError Specifies whether or not to report a DBCS string conversion overflow error as an ODBC trunctation error. 0 = Report DBCS string conversion overflow error as ODBC truncation error

1 = Ignore truncation error

0
DEBUG Specifies one or more debug options. To specify multiple debug options add together the values for the options that you want. In most cases you will not need to set this option. To determine the value for this keyword, add the values below that are associated with each option that you want.

2 = Return SQL_IC_MIXED for the SQL_IDENTIFIER_CASE option of SQLGetInfo

4 = Store all SELECT statements in the package

8 = Return zero for the SQL_MAX_QUALIFIER_NAME_LEN option of option of SQLGetInfo

16 = Add positioned UPDATEs / DELETEs into packages

32 = Convert static cursors to dynamic cursors

64 = Send the entire column size worth of data for variable length fields (VARCHAR, VARGRAPHIC, BLOB, etc.) Note, set this option with caution as this can have an adverse impact on performance.

128 = Subtract one from the SQLBindParameter sourcelength if the last character in the buffer is a null-terminator character.

256 = Ignore data decimal errors

512 = Ignore case warnings (SQL0402) for scrollable cursors

1024 = Disable variable length compression

2048 = Return no support for SQL_CVT_DATE when calling the SQLGetInfo's SQL_CONVERT_TIMESTAMP option.

32768 = If the result of a query results in a column being divided by 0, return a NULL value instead of an error.

0
TRUEAUTOCOMMIT Specifies how to handle autocommit support. In past ODBC drivers, turning autocommit on resulted in the server running under the *NONE isolation level. Now autocommit can run under any isolation level. Applications that require strict conformance to the SQL specification should use setting 1. Note that this setting requires that all files be journaled. Setting 0 offers better performance for most applications. See the SQL reference for further information on Transaction Isolation levels. 0 = run autocommit under the *NONE isolation level

Start of change1 = run autocommit under the isolation level that is set for the connection. The connection's isolation level is set using the SQLSetConnectAttr API and the SQL_ATTR_TXN_ISOLATION option. End of change

0
Start of changeNEWPWDEnd of change Start of changeSpecifies a new password used to override the current user's iSeries password. This option is only honored if set by an application. When using this option, the UID and PWD keywords should also be specified. End of change Start of changeNew password to useEnd of change Start of changenoneEnd of change
XALCS or XALooselyCoupledSupport Specifies whether locks are shared between loosely coupled distributed transaction branches. 0 = Locks are not shared

1 = Locks are shared

1 (for Windows®)

0 (for Linux®)

XALOCKTIMEOUT Specifies the maximum amount of time (in seconds) that a distributed transaction waits on a lock request before timing out. 0 = Use the default system setting

0 – 999999999 = the number of seconds to wait

0
XATXNTIMEOUT or XATransactionTimeout Specfies the amount of time (in seconds) that a distributed transaction waits before timing out. 0 = Wait indefinitely for the transaction to finish

0 – 999999999 = the number of seconds to wait

0