From: | Bruce Momjian <bruce(at)momjian(dot)us> |
---|---|
To: | cliff(at)krumvieda(dot)com |
Cc: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-general(at)postgresql(dot)org |
Subject: | Re: Transaction isolation and constraints |
Date: | 2007-12-16 06:41:52 |
Message-ID: | 200712160641.lBG6fqR20564@momjian.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
cliff(at)krumvieda(dot)com wrote:
> Hi, Tom:
>
> >Whichever one manages to get to the index page first will go through.
> >The second one will block waiting to see if the first one commits,
> >and will error out if so --- or proceed, if it aborts.
>
> I see, this makes sense. What if the two transactions insert rows
> that don't violate the constraint: will they be able to proceed in
> parallel? Or will one wait for the other, because they both need to
> update the shared index? I.e., does the mechanism work by waiting for
> one index update to commit before permitting the next?
They proceed in parallel. Backends wait only on specific rows that
conflict, not the index page.
--
Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
EnterpriseDB http://postgres.enterprisedb.com
+ If your life is a hard drive, Christ can be your backup. +
From | Date | Subject | |
---|---|---|---|
Next Message | Bruce Momjian | 2007-12-16 07:41:03 | Re: Recovering data via raw table and field separators |
Previous Message | Erik Jones | 2007-12-16 05:12:47 | Re: limits |