Re: logical column ordering

Поиск
Список
Период
Сортировка
От Alvaro Herrera
Тема Re: logical column ordering
Дата
Msg-id 20150227200258.GL2384@alvh.no-ip.org
обсуждение исходный текст
Ответ на Re: logical column ordering  (Arthur Silva <arthurprs@gmail.com>)
Ответы Re: logical column ordering
Список pgsql-hackers
Arthur Silva wrote:

> Sorry to intrude, I've been following this post and I was wondering if it
> would allow (in the currently planed form or in the future) a wider set of
> non-rewriting DDLs to Postgres. For example, drop a column without
> rewriting the table.

Perhaps.  But dropping a column already does not rewrite the table, only
marks the column as dropped in system catalogs, so do you have a better
example.

One obvious example is that you have 

CREATE TABLE t (  t1 int,  t3 int
);

and later want to add t2 in the middle, the only way currently is to
drop the table and start again (re-creating all dependant views, FKs,
etc).  With the patch you will be able to add the column at the right
place.  If no default value is supplied for the new column, no table
rewrite is necessary at all.

-- 
Álvaro Herrera                http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Andres Freund
Дата:
Сообщение: Re: logical column ordering
Следующее
От: Pavel Stehule
Дата:
Сообщение: Re: Providing catalog view to pg_hba.conf file - Patch submission