DB2 - Problem description
Problem IC79036 | Status: Closed |
SQLCONNECT SETS DBNAME INTO DATA SOURCE NAME EVEN IF USER SPECIFIES DBALIAS, THIS CAUSES -842/-1024 IN SUBSEQUENT API. | |
product: | |
DB2 FOR LUW / DB2FORLUW / 980 - DB2 | |
Problem description: | |
SQLConnect sets dbname into data source name even if user specifies dbalias, this causes SQL0842N or SQL1024N in subsequent API calls. The following scenario would fail if a database has more than one alias. NOTE: where dbAlias is an alias for dbName. Case 1: Subsequesnt connection request fails with SQL0842N (Already connected) SQLConnect(hDbc, dbName..); SQLConnect(hDbc, dbAlias..); Case 2: DB2 API (db2CfgGet in this case) reports SQL1024N (No connection) SQLConnect(hDbc, dbAlias..); cfgStruct.dbname = dbAlias; db2CfgGet(db2Version970, (void *)&cfgStruct, &sqlca); | |
Problem Summary: | |
**************************************************************** * USERS AFFECTED: * * Users who use CLI application against a database which has * * more than one database alias(es). * **************************************************************** * PROBLEM DESCRIPTION: * * SQLConnect sets dbname into data source name even if user * * specifies dbalias, this causes SQL0842N or SQL1024N in * * subsequent API calls. * **************************************************************** * RECOMMENDATION: * * Please upgrade to DB2 V9.8 FixPack 5 or later. * **************************************************************** | |
Local Fix: | |
please remove dbalias. | |
Solution | |
This problem was first fixed in DB2 V9.8 FixPack 5. | |
Workaround | |
not known / see Local fix | |
Timestamps | |
Date - problem reported : Date - problem closed : Date - last modified : | 03.10.2011 19.06.2012 19.06.2012 |
Problem solved at the following versions (IBM BugInfos) | |
9.8.FP5 | |
Problem solved according to the fixlist(s) of the following version(s) | |
9.8.0.5 |