ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Excel xlodbc error 2042 with SQLRetrieve (https://www.excelbanter.com/excel-programming/335772-excel-xlodbc-error-2042-sqlretrieve.html)

ALK[_2_]

Excel xlodbc error 2042 with SQLRetrieve
 
I'm using XLODBC.XLA to execute stored procedures, and return rows to Excel.
There is one procedure that is returning 340 rows from a table, and it
returns the rows to Excel, but the SQLRetieve is returning 'Error 2042'
instead of the number of rows returned.

If I delete any row from the table before running the query, it works fine,
and returns the number of rows as it should. Even if I add a row, it works
fine, but something goes wrong when the record set is 340 rows. There are
probably other record set sizes that cause this problem, but so far this is
the first one my users have stumled on. Any ideas ?

thanks,
Andy

SQLExecQuery idConnect, sSQL
rc = SQLRetrieve(idConnect, output, , , bLabels)




All times are GMT +1. The time now is 07:30 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com