Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> comp.databases.theory -> Re: Basic question?What 's the key if there 's no FD(Functional Dependencies)?

Re: Basic question?What 's the key if there 's no FD(Functional Dependencies)?

From: NENASHI, Tegiri <tnmail42_at_gmail.com>
Date: 7 Nov 2006 17:44:31 -0800
Message-ID: <1162950271.315517.144220@f16g2000cwb.googlegroups.com>


Aloha Kakuikanu wrote:
> NENASHI, Tegiri wrote:
> > Aloha Kakuikanu wrote:
> > > 2. Is the view
> > >
> > > select name, 'RMI' from (
> > > select name from RealPeople
> > > minus
> > > select name from Impostors
> > > )
> > > union
> > > select name, 'IMR' from (
> > > select name from Impostors
> > > minus
> > > select name from RealPeople
> > > )
> > > union
> > > select name, 'I' from (
> > > select name from RealPeople
> > > intersect
> > > select name from Impostors
> > > )
> > >
> > > updatable?
> > >
> >
> > I must think about 'minus' but I think it is not updatable because the
> > two legs of the coproduct exist in the database and the coproduct like
> > this is not updatable.
>
> You are counting legs?
>
> Seriously, this second view is perfectly updatable.

This second view is perfectly non-updatable.

Let 'i' be the impostors, 'r' the real people, '+' the union,' -' the minus, & the intersect. Suppose r and i are disjoint. Then, (r-i) 'rmi' + (i-r) 'ima' + (r&i) 'i' can be simplified to r 'rmi' + i 'ima'. You suppose wher the following insert goes, to 'r' or to 'i' ? Why ? Suppose one does not know that r and j are disjoint. Where the following insert goes, to 'r' or to 'i' ? Why ?

>Suppose we insert
> 'JanHidders' into the RealPeople. Then, in the view we see that a
> record
>
> {(name='JanHidders', typ='RMI')}
>
> is added. (The "typ" is the name of the second attribute in the view --
> I forgot to put an alias in the view definition).
>
> Now we have one more record in the set
>
> RealPeople minus Impostors
>

"Suppose we insert 'JanHidders' into the RealPeople" and suppose 'JanHidders' is an impostor and exists in 'i'.

Then this:

> while the sets
>
> Impostors minus RealPeople
> and
> Impostors intersect RealPeople
>
> remain the same.

....
is not correct.

> What does it mean? It means that view insertion
> translates into the RealPeople table insertion.

No it is not correct. Received on Tue Nov 07 2006 - 19:44:31 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US