News for hackers. Stuff that matters.
Re:I only know PHP. How do I write a Web application in Python? by zzzeek on Sunday May 06, 2012 @07:01PM (#3936707)
If you have more than one statement, then autocommit is usually wrong, and what you usually want is transaction-per-request. If you have exactly one statement, then autocommit is exactly identical to transaction-per-request.

Also part of the transaction-per-request pattern is that the transaction is started when the first statement is invoked. So there's no overhead for zero-statement requests either.

There are no comments on this comment yet.