Re: constraint modification on todo list
От | Tom Lane |
---|---|
Тема | Re: constraint modification on todo list |
Дата | |
Msg-id | 26196.1063287814@sss.pgh.pa.us обсуждение исходный текст |
Ответ на | Re: constraint modification on todo list (Jeroen Ruigrok/asmodai <asmodai@wxs.nl>) |
Ответы |
Re: constraint modification on todo list
|
Список | pgsql-hackers |
Jeroen Ruigrok/asmodai <asmodai@wxs.nl> writes: > -On [20030909 00:42], Tom Lane (tgl@sss.pgh.pa.us) wrote: >> IIRC, Oracle does not have rollback-able DDL. That might imply that the >> reason they have MODIFY CONSTRAINT is that in Oracle you can't use the >> above way to eliminate the window. Can you put ALTERs inside >> transactions at all in Oracle? > As one of the Oracle gurus at work told me: > DDL does an implicit commit, so no rollback possible. > It also shouldn't be necessary, because you cannot change a table which > is in use. > It attempts to do a table lock and it fails. Is that their excuse? We can't ALTER a table that's already in use when the first ALTER starts, either --- its attempt to exclusive-lock the table will fail. But once you get the exclusive lock, you can (in Postgres) perform a series of operations without fear that subsequently-started transactions will be able to see the incompletely changed state of the table. Evidently Oracle can't handle that. That's why they need to invent combination operations like MODIFY CONSTRAINT. regards, tom lane
В списке pgsql-hackers по дате отправления: