psycopg problem

Lee Harr missive at frontiernet.net
Thu Mar 11 18:19:53 EST 2004


> 1. psycopg:      when a command fails, it will terminate the trasaction 
> but it tells that it will ignore other commands until the end of the 
> transaction block
> 2. PyGreSQL:  when a command fails, it will terminate the trasaction but 
> it tells that it will ignore other commands until the end of the 
> transaction block
> 3. pyPgSQL:    when a command fails, it will terminate the trasaction 
> without furhter notice (!!!)
>
> I see big problems here. I tried these too: Oracle, FireBird, MS SQL, 
> SAP DB. I was able to run an erroneous SQL and then continue my transaction
> (e.g. execute other commands in the same transaction). In my situation, 
> I just can't tell if a command will fail or not. If would be too hard 
> and too slow
> to determine if a command will fail or not. Hey, this is why exceptions 
> was born! From the other side, I must be able to commit or rollback all 
> my changes
> at the end of the block, depending on several things. Can anybody help 
> me please?
>
>


You may want to ask this question on a postgres list.

My understanding is that this is just the way it works in
postgres. Once there is an error condition in the transaction
you cannot continue on and commit. You have to rollback.




More information about the Python-list mailing list