Re: Transactions to create pg_multixact members and offsets

From: Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
To: Dev Kumkar <devdas(dot)kumkar(at)gmail(dot)com>
Cc: "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: Re: Transactions to create pg_multixact members and offsets
Date: 2014-11-20 19:44:46
Message-ID: 20141120194446.GL1639@alvin.alvh.no-ip.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Dev Kumkar wrote:
> On Thu, Nov 20, 2014 at 11:15 PM, Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
> wrote:

> > Merely waiting does not, but more than one lock being acquired on a
> > tuple does cause a multixact to be created. Try SELECT FOR SHARE on two
> > transactions on the same tuple.
>
> Sure.
> Also what if there are only inserts/updates which transaction have and
> there are no explicit select queries?

If there are foreign keys on the tables, the system internally runs some
SELECT FOR KEY SHARE queries on the referenced tables (the ones
containing the primary or unique keys). You can get some multixacts
that way too.

--
Álvaro Herrera http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message zach cruise 2014-11-20 20:30:08 Re: better architecture?
Previous Message Adrian Klaver 2014-11-20 19:24:33 Re: better architecture?