Re: This script will crash the connection

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: This script will crash the connection
Дата
Msg-id 20451.980573479@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: This script will crash the connection  (Bruce Momjian <pgman@candle.pha.pa.us>)
Ответы Re: This script will crash the connection  (Bruce Momjian <pgman@candle.pha.pa.us>)
Список pgsql-hackers
Bruce Momjian <pgman@candle.pha.pa.us> writes:
> OK, added to TODO:
> * Allow NOTIFY in rules
>> 
>> Uh, what does that have to do with the problem?  It's certainly not
>> an accurate rendering of either the current or proposed status ...

> Oops, can you give me a line.  What was the issue?

"Allow NOTIFY in conditional rules" would be an approximation.  It's
not the whole story though, because presently we also have to fail
if the rule is applied to a query with conditions, even if the rule
itself is unconditional.  As of my last commit:

regression=# create rule r1 as on update to int4_tbl do notify foo;
CREATE
regression=# update int4_tbl set f1 = f1;
UPDATE 5
regression=# update int4_tbl set f1 = f1 where f1 < 0;
ERROR:  Conditional NOTIFY is not implemented

which is pretty ugly but at least it doesn't pretend to do something
it can't, which was the 7.0 behavior.  (In 7.0 you'd have gotten a
NOTIFY whether the update updated any rows or not.)
        regards, tom lane


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Bug in FOREIGN KEY
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: This script will crash the connection