X-Original-To: pgsql-sql@postgresql.org Received: from spampd.localdomain (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id 2BD0C47632B for ; Thu, 3 Apr 2003 09:38:06 -0500 (EST) Received: from sss.pgh.pa.us (unknown [192.204.191.242]) by postgresql.org (Postfix) with ESMTP id 1C47B476326 for ; Thu, 3 Apr 2003 09:38:05 -0500 (EST) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.12.9/8.12.9) with ESMTP id h33Ec72L028223; Thu, 3 Apr 2003 09:38:07 -0500 (EST) To: "Marc G. Fournier" Cc: pgsql-sql@postgresql.org Subject: Re: simple trigger question ... In-reply-to: <20030403061142.V72033@hub.org> References: <20030402223933.M71125@hub.org> <25296.1049341477@sss.pgh.pa.us> <20030403000605.U71125@hub.org> <25512.1049343373@sss.pgh.pa.us> <20030403002922.Y71125@hub.org> <25618.1049344429@sss.pgh.pa.us> <20030403061142.V72033@hub.org> Comments: In-reply-to "Marc G. Fournier" message dated "Thu, 03 Apr 2003 06:12:55 -0400" Date: Thu, 03 Apr 2003 09:38:07 -0500 Message-ID: <28222.1049380687@sss.pgh.pa.us> From: Tom Lane X-Spam-Status: No, hits=-32.3 required=5.0 tests=BAYES_00,EMAIL_ATTRIBUTION,IN_REP_TO,QUOTED_EMAIL_TEXT, REFERENCES,REPLY_WITH_QUOTES autolearn=ham version=2.50 X-Spam-Level: X-Spam-Checker-Version: SpamAssassin 2.50 (1.173-2003-02-20-exp) X-Archive-Number: 200304/36 X-Sequence-Number: 12737 "Marc G. Fournier" writes: > 'K, that makes it workable ... final question (I hope!) ... RULEs vs > TRIGGERs? I ended up doing it as a RULE, since I could do it without a > function ... but is there a reason why that is a Bad Idea? Or in a case > like this, it doesn't really matter? A lot of people have found that rules don't behave quite the way they want, particularly with regard to things like the number of times that side-effects happen. Better test it out. regards, tom lane