Received: from maia.hub.org (maia-2.hub.org [200.46.204.251]) by mail.postgresql.org (Postfix) with ESMTP id EED98632585 for ; Sun, 29 Aug 2010 11:36:03 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.251]) (amavisd-maia, port 10024) with ESMTP id 11173-05 for ; Sun, 29 Aug 2010 14:35:55 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by mail.postgresql.org (Postfix) with ESMTP id A90B96323BD for ; Sun, 29 Aug 2010 11:35:56 -0300 (ADT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.2/8.14.2) with ESMTP id o7TEZrc3016394; Sun, 29 Aug 2010 10:35:53 -0400 (EDT) To: Thom Brown cc: pgsql-docs Subject: Re: Column-level triggers in docs In-reply-to: References: Comments: In-reply-to Thom Brown message dated "Sun, 29 Aug 2010 14:29:23 +0100" Date: Sun, 29 Aug 2010 10:35:53 -0400 Message-ID: <16393.1283092553@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.91 tagged_above=-5 required=5 tests=BAYES_00=-1.9, T_RP_MATCHES_RCVD=-0.01 X-Spam-Level: X-Archive-Number: 201008/115 X-Sequence-Number: 5939 Thom Brown writes: > I notice that the 9.0 docs page for CREATE TRIGGER doesn't indicate > column-level syntax in the synopsis: > http://www.postgresql.org/docs/9.0/static/sql-createtrigger.html My recollection is that we did it that way deliberately. The originally submitted patch tried to explain this as part of the syntax diagram, but it was (a) confusing and (b) not correct in detail. > So it would read something like: > CREATE TRIGGER name { BEFORE | AFTER } { event [ OF column_name [, ... > ] ] [ OR ... ] } If you do this then it looks like "OF column_name" can be attached to all four event types, which is wrong. So you end up needing just as much verbal annotation as in the current arrangement. regards, tom lane