question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Missing connection autocommit documentation

See original GitHub issue

It is unclear at the moment whether autocommit can be turned on on a given connection. From https://github.com/aws/amazon-redshift-python-driver/blob/master/redshift_connector/core.py#L417 it seems that it should be possible by setting connection.autocommit = True, but it is unclear if this would work as expected. It would be great to document this.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:1
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
Brooke-whitecommented, Mar 8, 2021

Documentation for autocommit has been added as of v2.0.875

1reaction
Brooke-whitecommented, Mar 3, 2021

Hey @GergelyKalmar ,

Thanks for reporting this issue – we will add some documentation regarding auto commit in our next release. By default connection.autocommit is set to False per PEP-249 ref

Setting connection.autocommit to True does indeed enable autocommit.

Read more comments on GitHub >

github_iconTop Results From Across the Web

The connection class — Psycopg 2.9.5 documentation
By default, Psycopg opens a transaction before executing the first command: if commit() is not called, the effect of any data manipulation will...
Read more >
AUTOCOMMIT and ODBC Transactions - Vertica
The AUTOCOMMIT connection attribute controls whether INSERT, ALTER, COPY and other data-manipulation statements are automatically committed after they complete.
Read more >
Working with Engines and Connections — SQLAlchemy 2.0 ...
When the block ends, the Connection object will revert the “autocommit” isolation level, and the DBAPI connection is released to the connection pool...
Read more >
JDBC auto-commit mode - IBM
By default, JDBC uses an operation mode called auto-commit. This means that every update to the database is immediately made permanent.
Read more >
possible documentation mistake on cursor/transaction #511
This is supported by the error I get when running the current example: Message: 'pyodbc.Cursor' object has no attribute 'autocommit'.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found