Re: "OLD used in query that is not in a rule"

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: "OLD used in query that is not in a rule"
Дата
Msg-id 25303.1332773516@sss.pgh.pa.us
обсуждение исходный текст
Ответ на "OLD used in query that is not in a rule"  ("Gauthier, Dave" <dave.gauthier@intel.com>)
Ответы Re: "OLD used in query that is not in a rule"  ("Gauthier, Dave" <dave.gauthier@intel.com>)
Список pgsql-general
"Gauthier, Dave" <dave.gauthier@intel.com> writes:
> I get... "OLD used in query that is not in a rule" when trying to ref, for example, OLD.tblcol1, from inside a stored
procedure. Is this saying you cannot use OLD.* (or NEW.* I suppose) unless it's from within a trigger function (returns
type"trigger")? 

Certainly.  You'd have to pass the field (or whole record) as a
parameter.  It's not some kind of magic global variable, it's
a predefined local variable in a trigger function (or rule).

            regards, tom lane

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

Предыдущее
От: "Gauthier, Dave"
Дата:
Сообщение: "OLD used in query that is not in a rule"
Следующее
От: "Gauthier, Dave"
Дата:
Сообщение: Re: "OLD used in query that is not in a rule"