If you are connecting to DB2 v10 on a Mainframe z/OS and need to load data using SQL queries, you must add special register CURRENT query acceleration in the Trillium config.txt file. The value you specify for this register identifies when DB2 submits dynamic SQL queries to an accelerator server and how DB2 manages accelerator server failures.
In the key rdbms section of the config.txt file, you add the following entry:
value db2_current_query_acceleration
"value"
The following values (as specified by IBM) are supported:
-
ALL. Specifies that queries are accelerated if they are eligible for acceleration. DB2 does not use cost information to determine whether to accelerate the queries. Queries that are not eligible for acceleration are not executed by DB2, and an SQL error is returned. If an accelerator failure occurs while a query is running or if the accelerator returns an error, DB2 returns a negative SQLCODE to the application.
-
NONE. Specifies that no queries are sent to an accelerator server.
-
ENABLE. Specifies that queries are accelerated only if DB2 determines that it is advantageous to do so. If an accelerator failure occurs while a query is running or if the accelerator returns an error, DB2 returns a negative SQLCODE to the application.
-
ENABLE_WITH_FAILBACK. Specifies that queries are accelerated only if DB2 determines that it is advantageous to do so. If the accelerator returns an error during the PREPARE or first OPEN for the query, DB2 executes the query without the accelerator. If the accelerator returns an error during a FETCH or a subsequent OPEN, DB2 returns the error and does not execute the query.
-
ELIGIBLE. Specifies that queries are accelerated if they are eligible for acceleration. DB2 does not use cost information to determine whether to accelerate the queries. Queries that are not eligible for acceleration are executed by DB2. If an accelerator failure occurs while a query is running or if the accelerator returns an error, DB2 returns a negative SQLCODE to the application.
For more information about query acceleration, see the IBM Knowledge Center.
To configure query acceleration
-
Open ...\MBSW\17\etc\config.txt file.
-
Add the entry and specify a supported value to the key rdbms section.
For example:
key rdbms { value uncommitted_read "on" value records_read 100 value records_read_odbc 1000 value
db2_current_query_acceleration
"ALL" } -
Save your changes and close the file.