Re: deadlock problem in Ad serving..
От
Ron Mayer
Тема
Re: deadlock problem in Ad serving..
Дата
Msg-id
Pine.LNX.4.33.0301200949540.13721-100000@ron
Ответ на
Re: deadlock problem in Ad serving.. (Tom Lane)
Список
Дерево обсуждения
deadlock problem in Ad serving.. "Rajesh Kumar Mallah." <mallah@trade-india.com>
Re: deadlock problem in Ad serving.. Bhuvan A <bhuvansql@myrealbox.com>
Re: deadlock problem in Ad serving.. "Rajesh Kumar Mallah." <mallah@trade-india.com>
Re: deadlock problem in Ad serving.. Tom Lane <tgl@sss.pgh.pa.us>
Re: deadlock problem in Ad serving.. "Rajesh Kumar Mallah." <mallah@trade-india.com>
Re: deadlock problem in Ad serving.. Ron Mayer <ron@intervideo.com>
Re: deadlock problem in Ad serving.. Tom Lane <tgl@sss.pgh.pa.us>
Re: deadlock problem in Ad serving.. Ron Mayer <ron@intervideo.com>
Re: deadlock problem in Ad serving.. "Christian Brink" <cb@onsitetech.com>
On Mon, 20 Jan 2003, Tom Lane wrote: > > Bhuvan A writes: > >> Error:...deadlock detected... > > ... You can overcome this by locking the table in share row > > exclusive mode also... > > ...use shorter transactions (one per page, not one per several pages). Hmm... with his query: "update banner_stats set imp=imp+1 where uniqid=4330" Is it true that the problem happens when updates are done in a different order by two transactions like this: trans.1: "update banner_stats set imp=imp+1 where uniqid=4330" trans.2: "update banner_stats set imp=imp+1 where uniqid=10" trans.1: "update banner_stats set imp=imp+1 where uniqid=10" trans.2: "update banner_stats set imp=imp+1 where uniqid=4330" If so, then could the problem be avoided if in his application logic he always did the updates in the same order? ... I.e. Make sure the each transaction does the updates in the same order by sorting his updates based on uniqid in the client? Ron
В списке pgsql-admin по дате отправления