Re: Trigger question

Поиск
Список
Период
Сортировка
От Richard Huxton
Тема Re: Trigger question
Дата
Msg-id 200401151610.38270.dev@archonet.com
обсуждение исходный текст
Ответ на Trigger question  (pginfo <pginfo@t1.unisoftbg.com>)
Ответы Re: Trigger question  (Evil Azrael <evilazrael@evilazrael.de>)
Список pgsql-performance
On Thursday 15 January 2004 13:13, pginfo wrote:
> Hi,
>
> I am using pg 7.4.1 and have created a trigger over table with 3 M rows.
> If I start masive update on this table, pg executes this trigger on
> every row and dramaticaly slows the system.
> Exists in pg any way to define the trigger execution only if I have
> changes on some fields?

Not at the moment (and I don't know of any plans for it).

> For example I am able to declare this in oracle.
> My trigger is writen in pgSQL.

Hmm - I can only think of two things you can try:
1. check for the change first thing you do and exit if not there
2. do the same, but write the trigger function in 'C'

--
  Richard Huxton
  Archonet Ltd

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

Предыдущее
От: "Rigmor Ukuhe"
Дата:
Сообщение: Weird query speed
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Weird query speed