Re: ALTER TABLE ... ALTER COLUMN ... SET DISTINCT

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Joshua Tolley <eggyknap(at)gmail(dot)com>, Jaime Casanova <jcasanov(at)systemguards(dot)com(dot)ec>, ITAGAKI Takahiro <itagaki(dot)takahiro(at)oss(dot)ntt(dot)co(dot)jp>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: ALTER TABLE ... ALTER COLUMN ... SET DISTINCT
Date: 2009-05-05 16:16:32
Message-ID: 603c8f070905050916w7a008053g1fa48e295e712fd4@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, May 5, 2009 at 12:13 PM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> Robert Haas <robertmhaas(at)gmail(dot)com> writes:
>> On Mon, May 4, 2009 at 10:41 PM, Joshua Tolley <eggyknap(at)gmail(dot)com> wrote:
>>> A question: why does attdistinct become entry #5 instead of going at the end?
>>> I assume it's because the order here controls the column order, and it makes
>>> sense to have attdistinct next to attstattarget, since they're related. Is
>>> that right? Thanks in advance...
>
>> Yep, that was my thought.
>
> We generally want fixed-size columns before variable-size ones, to ease
> accessing them from C code.  So it shouldn't go at the end in any case.
> Beyond that it's mostly aesthetics, with maybe some thought for avoiding
> unnecessary alignment padding.

I thought about that as well; it should be OK where it is, in that regard.

...Robert

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Andrew Dunstan 2009-05-05 16:19:05 Re: bytea vs. pg_dump
Previous Message Tom Lane 2009-05-05 16:13:15 Re: ALTER TABLE ... ALTER COLUMN ... SET DISTINCT