Re: [SQL] 100% CPU at concurent access

2008-10-10 Thread Sabin Coanda
I find the problem is in my outer procedure, because it has no sleep there, and I change it calling pg_sleep: -- Function: "TestProcOuter"() -- DROP FUNCTION "TestProcOuter"(); CREATE OR REPLACE FUNCTION "TestProcOuter"() RETURNS integer AS $BODY$ DECLARE Loops int4 := 1; BEGIN

Re: [SQL] 100% CPU at concurent access

2008-10-09 Thread Sabin Coanda
Hi Tom, Well, I thought the connection with the failed transaction checks in a loop until the succeeded transaction will finish, and then it will succeeded as well. However, would you suggest me a code for "TestProcOuter" that works and fulfils my desire, please ? :) Thanx, Sabin -- Sen

Re: [SQL] 100% CPU at concurent access

2008-10-08 Thread Tom Lane
"Sabin Coanda" <[EMAIL PROTECTED]> writes: > Then I try to use the following procedure to catch the concurrency access > occurence and retry until both scripts succeed: What makes you think they ever will succeed? Once one of these guys has hit a failure, you've got a tight loop of retryi