Re: Rule not invoked in 7.1 - Mailing list pgsql-sql

From Tom Lane
Subject Re: Rule not invoked in 7.1
Date
Msg-id 26488.980398409@sss.pgh.pa.us
Whole thread Raw
In response to Rule not invoked in 7.1  (Kyle <kyle@actarg.com>)
Responses Re: Rule not invoked in 7.1  (Jan Wieck <janwieck@Yahoo.com>)
List pgsql-sql
Kyle <kyle@actarg.com> writes:
> ERROR:  Cannot update a view without an appropriate rule.

7.1 insists that you provide an *unconditional* DO INSTEAD rule
for a view.  What do you think was happening on your old database
when the "where old.status = 'appr'" clause wasn't satisfied?
Nothing good I'm afraid.

If you really do need conditional rules, you can satisfy the check
by writing one unconditional DO INSTEAD NOTHING rule and then one
or more conditional non-INSTEAD rules.  But you should think carefully
about what you expect to happen when you use a conditional rule.
        regards, tom lane


pgsql-sql by date:

Previous
From: Som
Date:
Subject: Insertion and Retrieval of BLOB
Next
From: Christopher Sawtell
Date:
Subject: Re: SQL Query Results