pros/cons re constraints on audit tables

Поиск
Список
Период
Сортировка
От Karsten Hilbert
Тема pros/cons re constraints on audit tables
Дата
Msg-id 20030811000644.C21726@hermes.hilbert.loc
обсуждение исходный текст
Список pgsql-general
I have been using everyones favourite implementation of
auditing by using triggers on insert, update and delete the
concept for which has been posted here time and again
(mine comes complete with a Python script to auto-generate
the needed triggers on marked tables - mail me if interested).

Every so often it has been said that the audit trail tables
should not bear any constraints. I have so far used "not null"
constraints in my audit trail tables on those attributes that
are constrained thusly in the audited source table. I have
marvelled back and forth on whether this is a good idea many
times but haven't come to a conclusion.

So, if anyone thinks this is a really dumb thing to do please
tell me. Rational arguments and examples for when this would
fail are highly welcome.

Karsten
--
GPG key ID E4071346 @ wwwkeys.pgp.net
E167 67FD A291 2BEA 73BD  4537 78B9 A9F9 E407 1346

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

Предыдущее
От: Karsten Hilbert
Дата:
Сообщение: Re: OT: Address Fields
Следующее
От: Raymond
Дата:
Сообщение: Email DML Errors and Constraint Violations