I'm trying to use the ODBC function SQLGetInfo(), but I keep getting the error 'Too many arguments'.
The code I'm using is as follows:
***-----------start
#DEFINE SQL_DBMS_NAME 17
declare integer SQLGetInfo IN odbc32 integer, integer, string, integer, @integer
LOCAL lnHandle, lcRetString, lnOutputLen, lnInitLen
lnHandle = sqlconnect( "MyDSN", "sa", "" )
lcOutputString = SPACE( 300 )
lnOutputLen = 0
lnInitLen = 300
? SQLGetInfo( lnHandle, SQL_DBMS_NAME, @lcOutputStr, lnInitLen, @lnOutputLen )
sqldisconnect( lnHandle )
***------------- finish
As soon as I hit the SQLGetInfo line, I get the Too many arguments error.
Anyone got any suggestions?
Thanks,
Jamie
-----
Jamie Forgan
Senior Consultant
WST Pacific Pty Ltd