setting SQL_ATTR_ODBC_CURSORS attribute to SQL_CUR_USE_ODBC fails to open the libodbccr library on AIX

Scott Zhong <[email protected]> Fri, 6 Jun 2014 12:36:52 -0600
Newsgroups gmane.comp.db.unixodbc.devel
Message-ID <53D52D02E87FA04A948D9A74A7AE617C1543B264E6@Eagle.Blue.Roguewave.Com>
--===============0358387885==
Content-Language: en-US
Content-Type: multipart/alternative;
	boundary="_000_53D52D02E87FA04A948D9A74A7AE617C1543B264E6EagleBlueRogu_"

--_000_53D52D02E87FA04A948D9A74A7AE617C1543B264E6EagleBlueRogu_
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

Hi,

    unixODBC 2.3.2 on AIX 6.1 after setting SQL_ATTR_ODBC_CURSORS attribute=
 to SQL_CUR_USE_ODBC and then connecting to a data source (DB2 is used in t=
his testcase) produces an error about unable to open cursor library.

Testcase snippet:

...
SQLULEN attr_cur =3D SQL_CUR_USE_ODBC;
SQLSetConnectAttr (hdbc, SQL_ATTR_ODBC_CURSORS, (SQLPOINTER)(SQLLEN)attr_cu=
r, NULL);
SQLDriverConnect (hdbc, NULL, connStrIn, SQL_NTS, connStrOut, BUFFER_LEN, &=
connStrOutLen, SQL_DRIVER_NOPROMPT);
...

/>uname -srv
AIX 1 6
/>oslevel -s
6100-09-01-1341
/>xlC -qversion
IBM XL C/C++ for AIX, V12.1 (5765-J02, 5725-C72)
Version: 12.01.0000.0008
/>xlC -I$ODBC/include testcase_setconnectattr.cpp -L$ODBC/lib -lodbc -lpthr=
ead -liconv
/>./a.out QE197UTF dbtest1 zebco5

Using specified DSN : QE197UTF
setting SQL_ATTR_ODBC_CURSORS to "1"
DSN=3DQE197UTF;Uid=3Ddbtest1;Pwd=3Dzebco5
rc: -1
ERROR: 0:  01000 : [unixODBC][Driver Manager]Can't open cursor lib '/nfs/pa=
ckages/mdx/aix/ppc32/databases/unixodbc/2.3.2/etc/libodbccr.so' : file not =
found
Error in Step 1 -- SQLDriverConnect failed
Exiting!!

copying "libodbccr.a" to "/nfs/packages/mdx/aix/ppc32/databases/unixodbc/2.=
3.2/etc/libodbccr.so" does NOT fix the issue.

--_000_53D52D02E87FA04A948D9A74A7AE617C1543B264E6EagleBlueRogu_
Content-Type: text/html; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

<html xmlns:v=3D"urn:schemas-microsoft-com:vml" xmlns:o=3D"urn:schemas-micr=
osoft-com:office:office" xmlns:w=3D"urn:schemas-microsoft-com:office:word" =
xmlns:m=3D"http://schemas.microsoft.com/office/2004/12/omml" xmlns=3D"http:=
//www.w3.org/TR/REC-html40"><head><META HTTP-EQUIV=3D"Content-Type" CONTENT=
=3D"text/html; charset=3Dus-ascii"><meta name=3DGenerator content=3D"Micros=
oft Word 14 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
	{font-family:Calibri;
	panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
	{margin:0in;
	margin-bottom:.0001pt;
	font-size:11.0pt;
	font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
	{mso-style-priority:99;
	color:blue;
	text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
	{mso-style-priority:99;
	color:purple;
	text-decoration:underline;}
span.EmailStyle17
	{mso-style-type:personal-compose;
	font-family:"Calibri","sans-serif";
	color:windowtext;}
.MsoChpDefault
	{mso-style-type:export-only;
	font-family:"Calibri","sans-serif";}
@page WordSection1
	{size:8.5in 11.0in;
	margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
	{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext=3D"edit" spidmax=3D"1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext=3D"edit">
<o:idmap v:ext=3D"edit" data=3D"1" />
</o:shapelayout></xml><![endif]--></head><body lang=3DEN-US link=3Dblue vli=
nk=3Dpurple><div class=3DWordSection1><p class=3DMsoNormal>Hi,<o:p></o:p></=
p><p class=3DMsoNormal><o:p>&nbsp;</o:p></p><p class=3DMsoNormal>&nbsp;&nbs=
p;&nbsp; unixODBC 2.3.2 on AIX 6.1 after setting SQL_ATTR_ODBC_CURSORS attr=
ibute to SQL_CUR_USE_ODBC and then connecting to a data source (DB2 is used=
 in this testcase) produces an error about unable to open cursor library.<o=
:p></o:p></p><p class=3DMsoNormal><o:p>&nbsp;</o:p></p><p class=3DMsoNormal=
>Testcase snippet:<o:p></o:p></p><p class=3DMsoNormal><o:p>&nbsp;</o:p></p>=
<p class=3DMsoNormal>&#8230;<o:p></o:p></p><p class=3DMsoNormal>SQLULEN att=
r_cur =3D SQL_CUR_USE_ODBC;<o:p></o:p></p><p class=3DMsoNormal>SQLSetConnec=
tAttr (hdbc, SQL_ATTR_ODBC_CURSORS, (SQLPOINTER)(SQLLEN)attr_cur, NULL);<o:=
p></o:p></p><p class=3DMsoNormal>SQLDriverConnect (hdbc, NULL, connStrIn, S=
QL_NTS, connStrOut, BUFFER_LEN, &amp;connStrOutLen, SQL_DRIVER_NOPROMPT);<o=
:p></o:p></p><p class=3DMsoNormal>&#8230;<o:p></o:p></p><p class=3DMsoNorma=
l><o:p>&nbsp;</o:p></p><p class=3DMsoNormal>/&gt;uname -srv<o:p></o:p></p><=
p class=3DMsoNormal>AIX 1 6<o:p></o:p></p><p class=3DMsoNormal>/&gt;oslevel=
 -s<o:p></o:p></p><p class=3DMsoNormal>6100-09-01-1341<o:p></o:p></p><p cla=
ss=3DMsoNormal>/&gt;xlC -qversion<o:p></o:p></p><p class=3DMsoNormal>IBM XL=
 C/C++ for AIX, V12.1 (5765-J02, 5725-C72)<o:p></o:p></p><p class=3DMsoNorm=
al>Version: 12.01.0000.0008<o:p></o:p></p><p class=3DMsoNormal>/&gt;xlC -I$=
ODBC/include testcase_setconnectattr.cpp -L$ODBC/lib -lodbc -lpthread -lico=
nv<o:p></o:p></p><p class=3DMsoNormal>/&gt;./a.out QE197UTF dbtest1 zebco5<=
o:p></o:p></p><p class=3DMsoNormal><o:p>&nbsp;</o:p></p><p class=3DMsoNorma=
l>Using specified DSN : QE197UTF<o:p></o:p></p><p class=3DMsoNormal>setting=
 SQL_ATTR_ODBC_CURSORS to &quot;1&quot;<o:p></o:p></p><p class=3DMsoNormal>=
DSN=3DQE197UTF;Uid=3Ddbtest1;Pwd=3Dzebco5<o:p></o:p></p><p class=3DMsoNorma=
l>rc: -1<o:p></o:p></p><p class=3DMsoNormal>ERROR: 0:&nbsp; 01000 : [unixOD=
BC][Driver Manager]Can't open cursor lib '/nfs/packages/mdx/aix/ppc32/datab=
ases/unixodbc/2.3.2/etc/libodbccr.so' : file not found<o:p></o:p></p><p cla=
ss=3DMsoNormal>Error in Step 1 -- SQLDriverConnect failed<o:p></o:p></p><p =
class=3DMsoNormal>Exiting!!<o:p></o:p></p><p class=3DMsoNormal><o:p>&nbsp;<=
/o:p></p><p class=3DMsoNormal>copying &quot;libodbccr.a&quot; to &quot;/nfs=
/packages/mdx/aix/ppc32/databases/unixodbc/2.3.2/etc/libodbccr.so&quot; doe=
s NOT fix the issue.<o:p></o:p></p></div></body></html>=

--_000_53D52D02E87FA04A948D9A74A7AE617C1543B264E6EagleBlueRogu_--

--===============0358387885==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
unixODBC-dev mailing list
[email protected]
http://mailman.unixodbc.org/mailman/listinfo/unixodbc-dev

--===============0358387885==--