constraint with no check

Поиск
Список
Период
Сортировка
От Michał Zaborowski
Тема constraint with no check
Дата
Msg-id e2289d9e0803081256y19edd3b7g879db0317555452c@mail.gmail.com
обсуждение исходный текст
Список pgsql-hackers
Hello, I would like to be able to add CONSTRAINT, or DEFAULT with out
affecting old rows. Yes, it sounds strange, but... Let's say I have
big table, I want to add new column, with DEFAULT and NOT NULL.
Normally it means long exclusive lock. So - right now I'm adding plain
new column, then DEFAULT, then UPDATE on all rows in chunks, then NOT
NULL... Can it be little simpler?
 Also IMVHO it is good idea to release the exclusive lock just after
meta-data change. So, it would be nice to be able to release lock at
any time.
 That  jobs can be done in other ways, but new users can get in
troubles. Also explicit lock release can help with bulk updates. You
see - maybe it is not a "problem" - but doing all that some how silly
job - day by day... is boring.
 Hope it can help.

--
Regards, Michał Zaborowski (TeXXaS)

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Google Summer of Code 2008
Следующее
От: Dave Cramer
Дата:
Сообщение: Re: Doubt in index scan code