Re: More on view updates and inverse views

From: Tegiri Nenashi <tegirinenashi_at_gmail.com>
Date: Sun, 6 Sep 2009 12:54:01 -0700 (PDT)

On Sep 6, 12:29 pm, paul c <toledobythe..._at_oohay.ac> wrote:
> Tegiri Nenashi wrote:
> > Suppose we have views u, w defined as relational expressions over base
> > tables x, y, z:
>
> > u = f(x,y,z)
> > w = g(x,y,z)
>
> > Let's assume this system of equations is invertible, that is we can
> > solve it and express x, y, z as functions of u, w:
>
> > x = r(u,v)
> > y = s(u,v)
> > z = t(u,v)
>
> > Then, the system of views u,w is updatable. Given the new database
> > state reflected in the relations u, w, we can calculate base relations
> > by leveraging above expressions. One can object that it wouldn't be a
> > practical solution; on the plus side, however, increments and
> > decrements never enter the picture!
>
> I think as soon as one starts using functions to describe relations it's
> easy to loose track of important details.  In the above u=f(x,y,z) could
> result in a an rva,  If I understand what you're saying, to invert it,
> you'd have to back and make x an rva too but once you do that u becomes
> a kind of nested rva and you'll recurse forever!

I fail to see the nesting. Let assume u is a join of x, y, z:

u = x ^ y ^ z

while u is a union

w = x v y v z

To invert it we we to express x in terms of some relational operations over u and w. This is possible only if the system is not under- (or over-) constrained, and as we already established it is (even in the simpler case involving 2 relvars: x and y).

> Also, if one accepts that relational assignment is really what 'update'
> means, increments and decrements don't enter the picture in the first
> place. .

There is no assignment -- the equality sign means identity relation. Received on Sun Sep 06 2009 - 21:54:01 CEST

Original text of this message