Thread

  1. Re: Updateable views...

    Eric D Nielsen <nielsene@mit.edu> — 2003-03-05T15:39:02Z

    > Gavin Sherry <swm@linuxworld.com.au> writes:
    > > I haven't had time to look into it further, but it occurs to me that
    > > handling views which rely on joins would be far from trivial.
    > 
    > Views containing joins would not be updatable; problem solved. 
    
    I see how that is what the spec says, but aren't the majority of joins that
    people use/want to update a join of some type?  I thought that SQL99 allowed
    updating view created by joins.
    
    In either case is this a place where "exceeding" the spec would be a good 
    thing or a bad thing?
    
    Eric
    
    
  2. Re: Updateable views...

    Tom Lane <tgl@sss.pgh.pa.us> — 2003-03-05T15:47:44Z

    Eric D Nielsen <nielsene@MIT.EDU> writes:
    > In either case is this a place where "exceeding" the spec would be a good 
    > thing or a bad thing?
    
    Unless there is an obvious definition of what updating a join means
    (obvious not only to the implementor, but to the user) I think this
    is dangerous territory.
    
    			regards, tom lane
    
    
  3. Re: Updateable views...

    Rod Taylor <rbt@rbt.ca> — 2003-03-05T16:12:01Z

    On Wed, 2003-03-05 at 10:39, Eric D Nielsen wrote:
    > > Gavin Sherry <swm@linuxworld.com.au> writes:
    > > > I haven't had time to look into it further, but it occurs to me that
    > > > handling views which rely on joins would be far from trivial.
    > > 
    > > Views containing joins would not be updatable; problem solved. 
    > 
    > I see how that is what the spec says, but aren't the majority of joins that
    > people use/want to update a join of some type?  I thought that SQL99 allowed
    > updating view created by joins.
    > 
    > In either case is this a place where "exceeding" the spec would be a good 
    > thing or a bad thing?
    
    Lets try to meet the spec first, then debate about whether extending it
    is a good or bad thing :)
    
    -- 
    Rod Taylor <rbt@rbt.ca>
    
    PGP Key: http://www.rbt.ca/rbtpub.asc
    
  4. Re: Updateable views...

    Curt Sampson <cjs@cynic.net> — 2003-03-05T16:29:45Z

    On Wed, 5 Mar 2003, Eric D Nielsen wrote:
    
    > I see how that is what the spec says, but aren't the majority of joins that
    > people use/want to update a join of some type?  I thought that SQL99 allowed
    > updating view created by joins.
    >
    > In either case is this a place where "exceeding" the spec would be a good
    > thing or a bad thing?
    
    This is a case where exceeding the spec would be a very good thing.
    And there has been lots of research on how to make more complex views
    updatable; see Date's _Introduction to Database Systems, 7th Edition_
    for an in-depth discussion of this.
    
    That said, one step at a time is always good, and even having just the
    very simplest views updatable would be a very nice thing.
    
    cjs
    -- 
    Curt Sampson  <cjs@cynic.net>   +81 90 7737 2974   http://www.netbsd.org
        Don't you know, in this new Dark Age, we're all light.  --XTC
    
    
  5. Re: Updateable views...

    Greg Stark <gsstark@mit.edu> — 2003-03-05T17:00:10Z

    Tom Lane <tgl@sss.pgh.pa.us> writes:
    
    > Eric D Nielsen <nielsene@MIT.EDU> writes:
    > > In either case is this a place where "exceeding" the spec would be a good 
    > > thing or a bad thing?
    > 
    > Unless there is an obvious definition of what updating a join means
    > (obvious not only to the implementor, but to the user) I think this
    > is dangerous territory.
    
    Joins are a *BIG* part of the reason people want updateable views. In every
    single case that I updated a view it was a join. Just being able to update
    subsets of tables or restricted sets of columns is really a fairly trivial use
    of a powerful feature.
    
    In Oracle the constraint is fairly straightforward (at least to describe): 
    for each column you're updating the primary key of the table it came from has
    to be present in the view.
    
    
    -- 
    greg