Re: Triggers on columns

Поиск
Список
Период
Сортировка
От Itagaki Takahiro
Тема Re: Triggers on columns
Дата
Msg-id 20090909091836.9C78.52131E4D@oss.ntt.co.jp
обсуждение исходный текст
Ответ на Re: Triggers on columns  ("Kevin Grittner" <Kevin.Grittner@wicourts.gov>)
Ответы Re: Triggers on columns  (James Pye <lists@jwp.name>)
Список pgsql-hackers
"Kevin Grittner" <Kevin.Grittner@wicourts.gov> wrote:

> How much does that buy you versus including this at the start of
> trigger_func:

One of the benefits is that it could handle tuple modifications
by another trigger, that is discussed here: http://archives.postgresql.org/pgsql-hackers/2009-09/msg00161.php | 2.
Recheckconditions if NEW values are modified, but triggers that |    have been fired already are not executed twice.
 

In addition, some database developers think procedures of trigger
and its condition separately. They might use other DBMSs that supports
WHEN clause in other times [1][2][3]. (All of them use "WHEN" for the
syntax; that's why I proposed "WHEN" but not "WHERE".)

Also, it would be useful if we reuse trigger bodies multiple times
with different conditions.

[1] Oracle   http://download.oracle.com/docs/cd/B28359_01/appdev.111/b28370/create_trigger.htm
[2] IBM DB2
http://publib.boulder.ibm.com/infocenter/db2luw/v9/index.jsp?topic=/com.ibm.db2.udb.admin.doc/doc/r0000931.htm
[3] SQLite3   http://www.sqlite.org/lang_createtrigger.html

Regards,
---
ITAGAKI Takahiro
NTT Open Source Software Center




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

Предыдущее
От: Itagaki Takahiro
Дата:
Сообщение: Re: CREATE LIKE INCLUDING COMMENTS and STORAGES
Следующее
От: Robert Haas
Дата:
Сообщение: Re: LATERAL