X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (neptune.hub.org [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id 96E5AD1B4CE for ; Thu, 15 Jan 2004 17:10:36 +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 18728-08 for ; Thu, 15 Jan 2004 13:10:06 -0400 (AST) Received: from mailout01.sul.t-online.com (mailout01.sul.t-online.com [194.25.134.80]) by svr1.postgresql.org (Postfix) with ESMTP id B0E33D1B449 for ; Thu, 15 Jan 2004 13:09:49 -0400 (AST) Received: from fwd10.aul.t-online.de by mailout01.sul.t-online.com with smtp id 1AhB07-0002uS-02; Thu, 15 Jan 2004 18:09:47 +0100 Received: from router.azrael.de (GnWVPgZAge6SONVkgNkGUi6QAZqnh7oz1joH91Dla93Qw+H6xAHcZA@[80.141.241.70]) by fmrl10.sul.t-online.com with esmtp id 1AhAyY-0wzGT20; Thu, 15 Jan 2004 18:08:10 +0100 Received: from azrael.azrael.de (azrael.azrael.de [192.168.202.18]) by router.azrael.de (8.11.4/8.11.4) with ESMTP id i0FH8ps18568 for ; Thu, 15 Jan 2004 18:08:51 +0100 Date: Thu, 15 Jan 2004 18:08:11 +0100 From: Evil Azrael X-Priority: 3 (Normal) Message-ID: <1022542776.20040115180811@evilazrael.de> Cc: "pgsql-performance@postgresql.org" Subject: Re: Trigger question In-Reply-To: <200401151610.38270.dev@archonet.com> References: <400691EA.96598C34@t1.unisoftbg.com> <200401151610.38270.dev@archonet.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Seen: false X-ID: GnWVPgZAge6SONVkgNkGUi6QAZqnh7oz1joH91Dla93Qw+H6xAHcZA@t-dialin.net X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200401/158 X-Sequence-Number: 5333 Guten Tag Richard Huxton, Am Donnerstag, 15. Januar 2004 um 17:10 schrieben Sie: RH> On Thursday 15 January 2004 13:13, pginfo wrote: >> Hi, >> >> I am using pg 7.4.1 and have created a trigger over table with 3 M rows. >> If I start masive update on this table, pg executes this trigger on >> every row and dramaticaly slows the system. >> Exists in pg any way to define the trigger execution only if I have >> changes on some fields? That not, but perhaps a STATEMENT Level Trigger could help. It´s a new feature in 7.4.x and rather undocumented. http://www.postgresql.org/docs/current/interactive/sql-createtrigger.html "FOR EACH STATEMENT" probably this can help you a bit. Christoph Nelles -- Mit freundlichen Grüssen Evil Azrael mailto:evilazrael@evilazrael.de