Re: Sequence Access Method WIP

From: Petr Jelinek <petr(at)2ndquadrant(dot)com>
To: Andres Freund <andres(at)anarazel(dot)de>, Heikki Linnakangas <hlinnaka(at)iki(dot)fi>
Cc: Simon Riggs <simon(at)2ndQuadrant(dot)com>, Andres Freund <andres(at)2ndquadrant(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>, Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
Subject: Re: Sequence Access Method WIP
Date: 2015-04-20 10:26:15
Message-ID: 5534D447.2040701@2ndquadrant.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 20/04/15 12:05, Andres Freund wrote:
> On 2015-04-20 12:49:39 +0300, Heikki Linnakangas wrote:
>> With the patch, pg_class.relam column references to the pg_seqam table for
>> sequences, but pg_indexam for indexes. I believe it's the first instance
>> where we reuse a "foreign key" column like that. It's not a real foreign
>> key, of course - that wouldn't work with a real foreign key at all - but
>> it's a bit strange. That makes me a bit uncomfortable. How do others feel
>> about that?
>
> Hm. I'd modeled it more as an extension of the 'relkind' column
> mentally. I.e. it further specifies how exactly the relation is
> behaving. Given that the field has been added to pg_class and not
> pg_index, combined with it not having index in its name, makes me think
> that it actually was intended to be used the way it's done in the patch.
>

That's how I think about it too. It's also short for access method,
nothing really suggests to me that it should be index specific by design.

--
Petr Jelinek http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Michael Paquier 2015-04-20 12:01:46 Re: Supporting TAP tests with MSVC and Windows
Previous Message Andres Freund 2015-04-20 10:05:37 Re: Sequence Access Method WIP