[unixODBC-support] SQLSetConnectOption() with invalid attribute values returning success instead of returning S1009(Invalid attribute value)

Nick Gorham nick at lurcher.org
Fri May 22 16:09:32 BST 2009


G, Hemanth Kumar wrote:
>
> Hi,
>
>        I am using unixODBC-2.2.15pre DM on Z/Linux 32-bit OS to 
> connect to Teradata database.
> I observe SQLSetConnectOption() returning SQL_SUCCESS  even when 
> passed an invalid attribute values in these cases, whereas the 
> expected sqlstate is S1009 (ODBC VER 2).
>
> SQLSetConnectOption(hdbc, SQL_ATTR_NOSCAN,* **2*) 
> Expected: SQL_ERROR "S1009" (Invalid attribute value), 
> Received: SQL_SUCCESS
>
> SQLSetConnectOption(hdbc, SQL_ATTR_TXN_ISOLATION,* 5*) 
> Expected: SQL_ERROR "S1009" (Invalid attribute value), 
> Received: SQL_SUCCESS
>
> SQLGetConnectOption(hdbc,* SQL_ATTR_LOGIN_TIMEOUT*, &pvParam)
> Expected: SQL_SUCCESS,
> Received: 08003, [unixODBC][Driver Manager]Connnection does not exist
> (Even though the connection handle has been allocated successfully)
>
> Char TraceFile[10] = ""; // TraceFile argument is a blank value
> SQLSetConnectOption(hdbc, SQL_OPT_TRACEFILE, (UDWORD)*TraceFile*); 
> Expected: SQL_ERROR "S1009" (Invalid attribute value)
> Received: SQL_SUCCESS
>
> SQLSetConnectOption(hdbc, SQL_OPT_TRACEFILE,* 0*);
> Expected: SQL_ERROR "S1009" (Invalid attribute value)
> Received: SQL_SUCCESS.
>
> Can you verify once..
>
> Thanks
> Hemanth.
>
>                                                                                                                                                                                               
>
>
Ok, they should be fixed in the 2.2.15pre thats there now.

-- 
Nick


More information about the unixODBC-support mailing list