Re: [GENERAL] update view

From: Mike Mascari <mascarm(at)mascari(dot)com>
To: Brian Haney <brian(at)cybernaut(dot)com>, pgsql-general(at)postgresql(dot)org
Subject: Re: [GENERAL] update view
Date: 1999-11-27 03:28:30
Message-ID: 383F4FDE.71567C65@mascari.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Brian Haney wrote:

> I'm trying to update a table through a view and have read up on what
> constitutes an 'updatable' view. I created a simple test case and cannot
> get it to update the table through the view. In the transcript below,
> notice that when I update the view, I get 'UPDATE 0' with no error message
> or other complaints. What am I missing? Does PostgreSQL not support
> updating through views?

It does, but you must supply the RULE for what should happen in the event of
an INSERT, UPDATE, or DELETE. See Chapter 35 in the Programmer's Guide - The
Postgres Rule System, the section entitled "Rules on INSERT, UPDATE and
DELETE".

Hope that helps,

Mike

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Brian Haney 1999-11-27 08:16:48 update view
Previous Message Peter Eisentraut 1999-11-27 01:07:03 Re: [GENERAL] rule's and trigger's