Re: patch: Add columns via CREATE OR REPLACE VIEW - Mailing list pgsql-hackers

From Robert Haas
Subject Re: patch: Add columns via CREATE OR REPLACE VIEW
Date
Msg-id 603c8f070808071007h45979f0bqd17970f9f4349b4b@mail.gmail.com
Whole thread Raw
In response to Re: patch: Add columns via CREATE OR REPLACE VIEW  (Alvaro Herrera <alvherre@commandprompt.com>)
Responses Re: patch: Add columns via CREATE OR REPLACE VIEW  (Gregory Stark <stark@enterprisedb.com>)
List pgsql-hackers
> Hmm, maybe we need to pull off the project to separate logical attribute
> number from physical and position.  It sounds like it could make it
> easier for view modification.

Much easier!  It would be a nice feature to have for table as well.
Right now, if you have a table with columns (foo1, foo2, foo3, bar1,
bar2, bar3) and you decide to add column foo4, there's no way to put
it where you intuitively want to put it.  Not a big deal, but I'd
definitely use it if we had it.

However, it's not necessary to implement this in order to make
meaningful improvements to CREATE OR REPLACE VIEW.  I think the only
thing we need to agree on is that no future implementation of CREATE
OR REPLACE VIEW will ever implicitly rename a column.  If we agree on
column name as a measure of column identity, then the change I'm
proposing is forward-compatible with any other enhancements we may
want to make later.

...Robert


pgsql-hackers by date:

Previous
From: Andrew Dunstan
Date:
Subject: Re: patch: Add columns via CREATE OR REPLACE VIEW
Next
From: Alvaro Herrera
Date:
Subject: Re: patch: Add columns via CREATE OR REPLACE VIEW