Re: Triggers and Multiple Schemas.

Поиск
Список
Период
Сортировка
От Michael Fuhr
Тема Re: Triggers and Multiple Schemas.
Дата
Msg-id 20060308204146.GA56709@winnie.fuhr.org
обсуждение исходный текст
Ответ на Triggers and Multiple Schemas.  ("Paul Newman" <paul.newman@tripoint.co.uk>)
Список pgsql-general
On Tue, Mar 07, 2006 at 06:34:33AM -0000, Paul Newman wrote:
> However at the moment we are placing the trigger functions within each
> schema along with trigger itself. The reason is that we don't know of a
> function or a variable that says "Give me the schema of the trigger that
> is calling this function".

PL/pgSQL triggers receive the table's oid in TG_RELID.  You could
query pg_class and join to pg_namespace to get the table's schema
name.  Is that what you're looking for?

--
Michael Fuhr

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

Предыдущее
От: Scott Marlowe
Дата:
Сообщение: Re: Triggers and Multiple Schemas.
Следующее
От: Louis Gonzales
Дата:
Сообщение: Re: Triggers and Multiple Schemas.