Re: forcing a literal value in a column - Mailing list pgsql-general

From Karsten Hilbert
Subject Re: forcing a literal value in a column
Date
Msg-id 20030513170103.Z564@hermes.hilbert.loc
Whole thread Raw
In response to Re: forcing a literal value in a column  (Karsten Hilbert <Karsten.Hilbert@gmx.net>)
List pgsql-general
> in my audited tables I do this:
>  modify_when time stamp with time zone not null default CURRENT_TIMESTAMP check(modify_when=now()),
>
> This works on insert. However, on update a function runs
> via a trigger but fails with:
>  ExecReplace: rejected due to CHECK constraint audit_mark_modify_when

> Any help is appreciated. This is on 7.1.3 (I know that's
> rather old).
Never mind since it's still the old mistake with the check
constraint.

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


pgsql-general by date:

Previous
From: Bruno Wolff III
Date:
Subject: Re: Creating functions and triggers
Next
From: nolan@celery.tssi.com
Date:
Subject: Re: Creating functions and triggers