Re: Rules

From: Jan Wieck <janwieck(at)Yahoo(dot)com>
To: Peeter Smitt <peeter(dot)smitt(at)online(dot)ee>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: Rules
Date: 2001-01-02 23:51:07
Message-ID: 200101022351.SAA12469@jupiter.jw.home
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Peeter Smitt wrote:
> Hi
>
> I'm trying to make updateable view useing rules.
>
> CREATE RULE update_rule AS ON UPDATE TO table DO INSTEAD
> SELECT fun1(new);
>
> Thing is that backend gives this error.
> ERROR: parser: parse error at or near ")"
>
> What i'm doing wrong? Are there any other ways to make updatebale multi-table views?

There are, but you haven't read the documentation about the
rule system, which is a common mistake.

Read chapter 8 of the PostgreSQL Programmers manual for
details on how to setup updateable views.

Jan

--

#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me. #
#================================================== JanWieck(at)Yahoo(dot)com #

In response to

  • Rules at 2000-11-09 08:50:44 from Peeter Smitt

Browse pgsql-sql by date

  From Date Subject
Next Message jkakar 2001-01-03 00:01:18 Weird problem with script...
Previous Message Albert REINER 2001-01-02 23:26:50 Ensuring primary key is referenced at least once upon commit