zillow / ctds

Python DB-API 2.0 library for MS SQL Server
MIT License
83 stars 12 forks source link

autocommit set to false is not stopping autocommit #92

Closed simm42 closed 2 years ago

simm42 commented 2 years ago

Trying to use CTDS 0.1.13 with MS SQL server.

Both connecting with autocommit set to false and with setting autocommit on the connection to false.

Begin transaction works, however it seems that on any action following that a commit is still issued internally.

Have tested also issuing the SQL BEGIN TRANSACTION and ROLLBACK TRANSACTION

Sequance:

  1. BEGIN TRANSACTION
  2. INSERT STATEMENT
  3. ROLLBACK TRANSACTION

Rollback fails with error that there is no corresponding BEGIN transaction - as if the commit had already been called.