Hi, I connect my application to a PostgreSql 8.3 server with BeginReq=True (default) and TransactionIsolationLevel=tiReadCommitted. Everything works ok but when I check the server status using pgAdmin, my connection is in <Idle in transaction> state, that's because the method TZPostgreSQLConnection.StartTransactionSupport issues a "begin" after connecting. Is it really required?.
If I set BeginReq=False, the status becomes <Idle>, but the database commits every insert/update/delete, when it shouldn't because I've set a StartTransaction before that.
Can you help with this?
BeginReq and ReadCommitted
Moderators: gto, cipto_kh, EgonHugeist, olehs
-
- Junior Boarder
- Posts: 25
- Joined: 24.10.2006, 18:29
- Location: Córdoba, Argentina
- Contact:
BeginReq and ReadCommitted
Leonardo M. Ramé
http://leonardorame.blogspot.com
http://leonardorame.blogspot.com
- mdaems
- Zeos Project Manager
- Posts: 2766
- Joined: 20.09.2005, 15:28
- Location: Brussels, Belgium
- Contact:
That's the way zeoslib is designed right now. Probably because it's difficult to make sure the "begin" is issued before the first real "transactional" action is fired.
If somebody wants to think/code about it : just go on. It will not be a feature for the 6.6 release, however. Also, this change is not only postgres related. It must behave the same way over all drivers.
Mark
If somebody wants to think/code about it : just go on. It will not be a feature for the 6.6 release, however. Also, this change is not only postgres related. It must behave the same way over all drivers.
Mark