mirror of
https://github.com/psycopg/psycopg2.git
synced 2025-02-17 01:20:32 +03:00
Fixed incorrect and outdated connection.commit() doc
This commit is contained in:
parent
ee7890d700
commit
e369fb5f0d
|
@ -60,11 +60,17 @@ The ``connection`` class
|
||||||
pair: Transaction; Commit
|
pair: Transaction; Commit
|
||||||
|
|
||||||
.. method:: commit()
|
.. method:: commit()
|
||||||
|
|
||||||
Commit any pending transaction to the database. Psycopg can be set to
|
Commit any pending transaction to the database.
|
||||||
perform automatic commits at each operation, see
|
|
||||||
`~connection.set_isolation_level()`.
|
By default, Psycopg opens a transaction before executing the first
|
||||||
|
command: if `!commit()` is not called, the effect of any data
|
||||||
|
manipulation will be lost.
|
||||||
|
|
||||||
|
The connection can be also set in "autocommit" mode: no transaction is
|
||||||
|
automatically open, commands have immediate effect. See
|
||||||
|
:ref:`transactions-control` for details.
|
||||||
|
|
||||||
|
|
||||||
.. index::
|
.. index::
|
||||||
pair: Transaction; Rollback
|
pair: Transaction; Rollback
|
||||||
|
@ -77,7 +83,7 @@ The ``connection`` class
|
||||||
|
|
||||||
|
|
||||||
.. method:: close()
|
.. method:: close()
|
||||||
|
|
||||||
Close the connection now (rather than whenever `del` is executed).
|
Close the connection now (rather than whenever `del` is executed).
|
||||||
The connection will be unusable from this point forward; an
|
The connection will be unusable from this point forward; an
|
||||||
`~psycopg2.InterfaceError` will be raised if any operation is
|
`~psycopg2.InterfaceError` will be raised if any operation is
|
||||||
|
|
Loading…
Reference in New Issue
Block a user