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

G, Hemanth Kumar Hemanth.G at Teradata.com
Fri May 22 15:25:58 BST 2009


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.

 


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.unixodbc.org/pipermail/unixodbc-support/attachments/20090522/c27306a7/attachment.html>


More information about the unixODBC-support mailing list