Skip to content

Commit

Permalink
Added note about OR ROLLBACK/ON CONFLICT ROLLBACK.
Browse files Browse the repository at this point in the history
  • Loading branch information
gh committed May 28, 2005
1 parent cbe793a commit ea8a1cb
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions doc/usage-guide.txt
Expand Up @@ -730,3 +730,8 @@ If you want *autocommit mode*, then set **isolation_level** to None.
Otherwise leave it at it's default, which will result in a plain "BEGIN"
statement, or set it to one of SQLite's supported isolation levels: DEFERRED,
IMMEDIATE or EXCLUSIVE.

As pysqlite needs to keep track of the transaction state, you should not use
``OR ROLLBACK`` or ``ON CONFLICT ROLLBACK``. Instead, catch the
``IntegrityError`` and call the ``rollback`` method of the connection yourself.

0 comments on commit ea8a1cb

Please sign in to comment.