Re: the patch: support for DESC/NULLS FIRST/NULLS LAST

From: "Dave Page" <dpage(at)pgadmin(dot)org>
To: "Quan Zongliang" <quanzongliang(at)gmail(dot)com>
Cc: pgadmin-hackers(at)postgresql(dot)org
Subject: Re: the patch: support for DESC/NULLS FIRST/NULLS LAST
Date: 2008-11-18 08:58:57
Message-ID: 937d27e10811180058j37191606w1d8d31e8297af4b6@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-hackers

On Tue, Nov 18, 2008 at 4:41 AM, Quan Zongliang <quanzongliang(at)gmail(dot)com> wrote:
>> > Allow Sequence to be attached to existing int4/int8 columns
>> >
>> > It means to make sequence dialog can support the "OWNED BY" clause in
>> > "CREATE/ALTER SEQUENCE" statement?
>>
>> That's part of it. I think the TODO item is intended as something that
>> will be done on dlgColumn though.
>
> CREATE/ALTER TABLE statement don't support sequence clause, except that column's
> default value. To support OWNED BY on dlgColumn, I think it is not
> needed.
>
> First, I try to implement it in dlgSequence.
> It seems simpler than dlgColumn.
> Ok?

The point is to turn an existing column into a serial column. In
dlgSequence you can specify the dependency, but that doesn't help with
the default value of the exiting column.

The only logical place to do this is on dlgColumn, and that would
require at least 2 SQL queries - one to change the column default, and
one to add the dependency link (which is not a problem - we do that
all over the place).

However, I'm not convinced this feature is worth the effort. I don't
think it would be used very much at all.

> Or search the TODO list to find the other I can do.

There are plenty of other interesting things there :-)

--
Dave Page
EnterpriseDB UK: http://www.enterprisedb.com

In response to

Browse pgadmin-hackers by date

  From Date Subject
Next Message Dave Page 2008-11-18 09:01:59 TODO List
Previous Message Quan Zongliang 2008-11-18 04:41:30 Re: the patch: support for DESC/NULLS FIRST/NULLS LAST