Skip site navigation (1) Skip section navigation (2)

Re: Bizarre choice of case for RELKIND_PARTITIONED_TABLE

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Bizarre choice of case for RELKIND_PARTITIONED_TABLE
Date: 2017-03-08 00:02:04
Message-ID: 11145.1488931324@sss.pgh.pa.us (view raw, whole thread or download thread mbox)
Thread:
Lists: pgsql-hackers
Robert Haas <robertmhaas(at)gmail(dot)com> writes:
> On Tue, Mar 7, 2017 at 6:03 PM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
>> Hm, one would hope that the vast majority of code references are neither
>> of those, but rather "RELKIND_PARTITIONED_TABLE".

> For reasons which must've seemed good to whoever instituted the
> policy, pg_dump refers to relkinds using the bare letters rather than
> the constants.

Even in pg_dump, it appears to me that the large majority of relkind
references use the symbolic names.  Quite a few of the violations of
that policy look to be new ... and now that I see them, their days are
numbered.

> (And protocol message types don't even have defined constants.  Uggh.)

Yeah, that's a different issue, which boils down to the fact that in order
to do anything useful we'd need to clutter client-visible namespace with
the symbols.  I wouldn't be averse to doing something about it as long as
it's not done in postgres_ext.h, but if not there where?

			regards, tom lane


In response to

Responses

pgsql-hackers by date

Next:From: legrand legrandDate: 2017-03-08 00:02:48
Subject: Re: Statement-level rollback
Previous:From: Andres FreundDate: 2017-03-07 23:58:54
Subject: Re: WIP: [[Parallel] Shared] Hash

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group