Re: BUG #1740: Deferred foreign key constraint isn't deferred

Поиск
Список
Период
Сортировка
От Stephan Szabo
Тема Re: BUG #1740: Deferred foreign key constraint isn't deferred
Дата
Msg-id 20050630102136.G34918@megazone.bigpanda.com
обсуждение исходный текст
Ответ на BUG #1740: Deferred foreign key constraint isn't deferred  ("Daniel Cristian Cruz" <dccruz@mega.com.br>)
Список pgsql-bugs
On Thu, 30 Jun 2005, Daniel Cristian Cruz wrote:

> ALTER TABLE ONLY mat_comissao_itens
>     ADD CONSTRAINT mat_nf_saida_itens_pa_mat_comissao_itens FOREIGN KEY
> (mat_nfs_diretorio, mat_nfs_in_codigo, mat_nsi_in_ordem) REFERENCES
> mat_nf_saida_itens(mat_nfs_diretorio, mat_nfs_in_codigo, mat_nsi_in_ordem)
> ON UPDATE RESTRICT ON DELETE RESTRICT DEFERRABLE INITIALLY DEFERRED;
>
> BEGIN;
> DELETE FROM mat_nf_saida_itens WHERE mat_nsi_in_ordem = 2;
> UPDATE mat_comissao_itens SET mat_nsi_in_ordem = 1 WHERE mat_nsi_in_ordem =
> 2;
> COMMIT;

Referential actions are immediate (they're defined as actions that happen
upon the occurrance), it's the constraint checks that are deferrable with
the deferrable/initially deferred.

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

Предыдущее
От: "Bobi Ivanov"
Дата:
Сообщение: Re: BUG #1735: row number -1 is out of range 0..-1 error
Следующее
От: Daniel Cristian Cruz
Дата:
Сообщение: Re: BUG #1740: Deferred foreign key constraint isn't deferred