X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id 9D22FD1C9FD for ; Tue, 4 Nov 2003 22:55:32 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 01487-01 for ; Tue, 4 Nov 2003 18:55:02 -0400 (AST) Received: from davinci.ethosmedia.com (server228.ethosmedia.com [209.128.84.228]) by svr1.postgresql.org (Postfix) with ESMTP id AE94BD1CA03 for ; Tue, 4 Nov 2003 18:54:59 -0400 (AST) Received: from [66.219.92.2] (HELO temoku) by davinci.ethosmedia.com (CommuniGate Pro SMTP 4.0.2) with ESMTP id 3869369; Tue, 04 Nov 2003 14:55:44 -0800 Content-Type: text/plain; charset="iso-8859-1" From: Josh Berkus Reply-To: josh@agliodbs.com Organization: Aglio Database Solutions To: Jamie Lawrence , pgsql-sql@postgresql.org Subject: Re: Problems with NEW.* in triggers Date: Tue, 4 Nov 2003 14:52:34 -0800 User-Agent: KMail/1.4.3 References: <20031104223319.GA2879@clueinc.net> In-Reply-To: <20031104223319.GA2879@clueinc.net> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Message-Id: <200311041452.34214.josh@agliodbs.com> X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200311/22 X-Sequence-Number: 15837 Jamie, > Any thoughts on what I'm doing wrong?? Yes. If you want to modify the new data, you need to use a BEFORE trigger.= =20=20 AFTER triggers can't modify NEW, just read it. --=20 -Josh Berkus Aglio Database Solutions San Francisco