Thread: BUG #11088: posgres blocks when i don't commit
The following bug has been logged on the website: Bug reference: 11088 Logged by: Guido Email address: guido@sofer.com.ar PostgreSQL version: 9.3.5 Operating system: Linux Description: Hi, I encountered the next problem, i really don't know how to describe it in one sentence: I have one table 'TABLE' with a column 'COLUMN' and 'COLUMN' is a primary key I have two processes 'proc1' and 'proc2' proc1 inserts a row in 'TABLE' with 'A' in the column 'COLUMN'... AND IT DOESNT COMMIT proc2 tries to insert a row with 'A' in the column 'COLUMN' What happens is that posgres simply don't respond (not an error, nothing happens) Is that normal? maybe yes, if it is, sorry for taking your time...
"guido@sofer.com.ar" <guido@sofer.com.ar> wrote:=0A=0A> I have one table 'T= ABLE' with a column 'COLUMN' and=0A> 'COLUMN' is a primary key=0A>=0A> I ha= ve two processes 'proc1' and 'proc2'=0A>=0A> proc1 inserts a row in 'TABLE'= with 'A' in the column=0A> 'COLUMN'...=0A> AND IT DOESNT COMMIT=0A>=0A> pr= oc2 tries to insert a row with 'A' in the column 'COLUMN'=0A>=0A> What happ= ens is that posgres simply don't respond (not an error,=0A> nothing happens= )=0A>=0A> Is that normal?=0A=0AYes, that is expected, because until proc1 c= ommits or rolls back it=0Ais unknown whether the attempt by proc2 is an err= or.=A0 If proc1=0Arolls back or otherwise fails before commit, it is OK for= proc2 to=0Ainsert that row; otherwise the attempt is an error.=0A=0ADetail= s here:=0A=0Ahttp://www.postgresql.org/docs/current/interactive/mvcc.html= =0A=0A--=0AKevin Grittner=0AEDB: http://www.enterprisedb.com=0AThe Enterpri= se PostgreSQL Company