Re: [GENERAL] rule's and trigger's

Поиск
Список
Период
Сортировка
От Peter Eisentraut
Тема Re: [GENERAL] rule's and trigger's
Дата
Msg-id Pine.LNX.4.20.9911261447210.344-100000@localhost.localdomain
обсуждение исходный текст
Ответ на rule's and trigger's  ("J. Roeleveld" <j.roeleveld@softhome.net>)
Список pgsql-general
On 1999-11-25, J. Roeleveld mentioned:

> I was wondering if anyone knows what's being executed first,
> a Rule on a view, or a trigger set to 'before <something>' on a view?
>
> Eg. what's executed first? The RULE, or the TRIGGER?

The rules are done first. The reason is that the rules actually modify the
query before it gets to execution. In case of a view, a trigger would then
act on the query to the base table. Thus a trigger on a view might not
make too much sense.

See also the relevant chapters (39 & 41) in the Programmer's Guide.

--
Peter Eisentraut                  Sernanders väg 10:115
peter_e@gmx.net                   75262 Uppsala
http://yi.org/peter-e/            Sweden



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

Предыдущее
От: Matthew Leo
Дата:
Сообщение: Re: PostgreSQL
Следующее
От: Peter Eisentraut
Дата:
Сообщение: Re: [GENERAL] about speed