Re: Using rules to implement backward-compatible schema changes

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Using rules to implement backward-compatible schema changes
Дата
Msg-id 13418.1199171358@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Using rules to implement backward-compatible schema changes  (Mario Becroft <pgsql@becroft.co.nz>)
Ответы Re: Using rules to implement backward-compatible schema changes  (Mario Becroft <pgsql@becroft.co.nz>)
Список pgsql-sql
Mario Becroft <pgsql@becroft.co.nz> writes:
> The problem is that when inserting to the view, default values do not
> work as expected.

You need to attach the defaults to the view, viz
ALTER TABLE a ALTER COLUMN bar SET DEFAULT 5;

This is considered a feature not a bug, since you might want a
different default for inserts to the view than for inserts
directly to the underlying table.
        regards, tom lane


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

Предыдущее
От: Mario Becroft
Дата:
Сообщение: Using rules to implement backward-compatible schema changes
Следующее
От: Mario Becroft
Дата:
Сообщение: Re: Using rules to implement backward-compatible schema changes