How do I enable auto-commit?

Asked by ercanyuz

Hi,

what is the equivalent of connection.autocommit(True) in PySQLPool ? It's already mentioned in features list that you support it.

In my python code, I run a select query every five seconds. After a while, query somehow starts to return empty resultsets. When I used MySQLdb, enabling autocommit had solved this issue. But now I'm going to use threading, so I want to use your module.

thx
Ercan

Question information

Language:
English Edit question
Status:
Answered
For:
PySQLPool Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Nikoleta Verbeck (nerdynick) said :
#1

So far there is a Keyed argument for getNewConnection or PySQLConnection.PySQLConnection that is commitOnEnd=True.

I however didn't know about connection.autocommit. I will have to start using that when I rework the Threaded Transactions layer to resolve a few issues.

Can you help with this problem?

Provide an answer of your own, or ask ercanyuz for more information if necessary.

To post a message you must log in.