Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id 8447F475AAC for ; Fri, 18 Oct 2002 01:26:28 -0400 (EDT) Received: from davinci.ethosmedia.com (davinci.ethosmedia.com [209.10.40.250]) by postgresql.org (Postfix) with ESMTP id E6C27475AA1 for ; Fri, 18 Oct 2002 01:26:27 -0400 (EDT) Received: from [63.195.55.98] (account ) by davinci.ethosmedia.com (CommuniGate Pro WebUser 3.5.9) with HTTP id 1790713; Thu, 17 Oct 2002 22:27:14 -0700 From: "Josh Berkus" Subject: Re: Can I create working trigger on view To: ?????? ?.?. , pgsql-sql@postgresql.org X-Mailer: CommuniGate Pro Web Mailer v.3.5.9 Date: Thu, 17 Oct 2002 22:27:14 -0700 Message-ID: In-Reply-To: <1702162421.20021018090603@ien.ru> MIME-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 8bit X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200210/202 X-Sequence-Number: 9919 Acue, > Can I create working trigger on view? > > The problem is: > I need a plpgsql function that execute on insert (or update, > or delete) into view and knows the *OLD* and *NEW*. > (Number of fields can be more than 16) No. Create a RULE instead, which can be created on a view: http://www.us.postgresql.org/users-lounge/docs/7.2/postgres/rules.html BTW, you can increase the number of parameters accepted by functions by re-compiling postgres. Also, 7.3 will have 32 as the default. -Josh Berkus