Rules and Triggers: another question

Поиск
Список
Период
Сортировка
От Jerome Chochon
Тема Rules and Triggers: another question
Дата
Msg-id 012c01c25d4e$57791320$80a337c1@pclisi17
обсуждение исходный текст
Список pgsql-sql
Hi all.
 
Sorry to ask you another time this question.
Which one is the faster ?

If i write this trigger...
CREATE TRIGGER trigger_name
BEFORE DELETE
ON table_name
FOR EACH ROW EXECUTE PROCEDURE function();

and this rule:
CREATE RULE name_rule AS
ON DELETE TO table_name
DO select function();

When i delete values, which one will call the function the first ?

Someone can help me ??
 
And if I want to use only function, do I use Trigger or Rules ?

(Thanks to M. Michael Paesold to answer my question but I want another answer to be sure)
 
Best Regards.
 
Jérêom Chochon

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Timestamp Fractions Problem
Следующее
От: "Florian Mader"
Дата:
Сообщение: Re: Timestamp Fractions Problem