Referential integrity problem postgresql 7.2 ?

Поиск
Список
Период
Сортировка
От srb@cuci.nl (Stephen R. van den Berg)
Тема Referential integrity problem postgresql 7.2 ?
Дата
Msg-id 20020610215833.GA1782@cuci.nl
обсуждение исходный текст
Ответы Re: Referential integrity problem postgresql 7.2 ?  (Stephan Szabo <sszabo@megazone23.bigpanda.com>)
Список pgsql-bugs
Should the following piece of code cause an:
ERROR:  <unnamed> referential integrity violation - key referenced
 from b not found in a
Or should it work because the check is deferred and in the
end no violations are present?

create table a(ia int primary key);
create table b(ia int references a initially deferred);
insert into a values (7);
begin;
insert into b values (-7);
update b set ia=-ia where ia<0;
commit;
drop table a;
drop table b;

--
Sincerely,                                                          srb@cuci.nl
           Stephen R. van den Berg (AKA BuGless).

"-- hit any user to continue"

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

Предыдущее
От: "vikas p verma"
Дата:
Сообщение: PostGres Doubt
Следующее
От: Matej Hollý
Дата:
Сообщение: referential integrity error