Trying to reproduce Google issue 277
Cursor objects can now be used in "with" statements and will automatically commit the transaction if successful. This is part of the effort to allow programs to be written using only Cursors. There are times when having separate connections and cursors are necessary, but very rare. By duplicating connection functionality in the cursor, most programs can probably use a single Cursor object everywhere.
…xecute. (Lost fix) This was fixed in 2.1.12 and lost during the Python 3 conversion. The saved prepared statement was not cleaned up when a SQLTables or similar function was used. If the next execute used the same SQL, pyodbc did not call SQLPrepare. (cherry picked from commit 7fdec2f)
Removed deprecated Row_slice. The sequence structure changed this from an actual function pointer to a void pointer. GCC 4.6.2 would not allow the assignment of Row_slice to void*. This may not build under 2.5. Also eliminated a bunch of casts to see if newer GCC would uncover other issues.