Open GoogleCodeExporter opened 8 years ago
I get the same issue using Ubuntu 12.04 with FreeTDS and unixodbc connecting to
SQL server 2005. The work around works but it's really held me up for a long
time figuring it out...
Original comment by j...@duckworth.me
on 5 Feb 2013 at 11:03
Probably need to check the resultset for DONE_IN_PROC... see here:
http://ask.sqlservercentral.com/questions/1390/what-does-set-nocount-on-do.html
"A while back, some ODBC libraries got entirely confused by DONE_IN_PROC
messages, so it was actually needed in order to make client code function
correctly. I don't believe that is the case any more with current generation
libraries."
...except pyodbc
Original comment by j...@duckworth.me
on 5 Feb 2013 at 11:06
Thanks. It is often confusing, but I'm not sure it shouldn't work that way.
The INSERT statements generate a result (which is controlled by the database).
I'm going to keep this open and think about it. The library does recognize
that there are no rows (by asking for the number of columns or rows). It could
try going to the next result set automatically and if there isn't one, keep the
previous rowcount. This would work for people that use a single statement per
execute().
Original comment by mkleehammer
on 29 Mar 2013 at 12:09
Original issue reported on code.google.com by
WSKi...@gmail.com
on 8 Nov 2012 at 3:57