Skip site navigation (1) Skip section navigation (2)

Re: Updateable views...

From: Neil Conway <neilc(at)samurai(dot)com>
To: Eric D Nielsen <nielsene(at)MIT(dot)EDU>
Cc: PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Updateable views...
Date: 2003-03-05 00:20:29
Message-ID: 1046823629.10528.7.camel@tokyo (view raw or flat)
Thread:
Lists: pgsql-hackers
On Tue, 2003-03-04 at 15:26, Eric D Nielsen wrote:
> The one place I haven't been able to use PostGreSQL to experiment is with
> regards to updateable views.  I've found a few threads in -general and -hackers
> (including one linked from the ToDo list), but they all seem to die out without
> really reaching any sort of conclusion.  I've also seen that in many
> cases it appears possible to use triggers/rules to simulate updateable views,
> but that feels like an inelegant solution to me.

How so? A view is defined by ON SELECT rules; it seems natural, then,
that an updateable view would be defined ON INSERT / ON UPDATE rules.
AFAIK the only deficiency with the status quo is that the system does
not automatically define those insertion rules for you (in the subset of
cases where rules actually *can* be defined: for example, the view can't
include aggregation/grouping, calls to a user-defined function, etc.)

If you'd like to work on getting PostgreSQL to make views updateable
automatically, that would be cool -- AFAIK no one else is currently
working on it.

Cheers,

Neil
-- 
Neil Conway <neilc(at)samurai(dot)com> || PGP Key ID: DB3C29FC




In response to

Responses

pgsql-hackers by date

Next:From: Christopher Kings-LynneDate: 2003-03-05 01:14:36
Subject: Re: Best setup for RAM drive
Previous:From: Tom LaneDate: 2003-03-05 00:14:23
Subject: Re: [PATCHES] ALTER SEQUENCE

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group