Re: Basic question?What 's the key if there 's no FD(Functional Dependencies)?
Date: 8 Nov 2006 13:28:35 -0800
Message-ID: <1163021315.848045.276460_at_f16g2000cwb.googlegroups.com>
Aloha Kakuikanu wrote:
> NENASHI, Tegiri wrote:
> > 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?
> > > > >
> > > 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 ?
>
> OK. I have to do complete case-by-case analysis:
> 1) A record is inserted into RMI. Nothing gets inserted into IMR and
> into I.
This is different of your preceding question. You have never said that you insert into RMI. Please you must learn how to pose questions correctly.
The insertion of record is possible only when the realpeople and impostors are disjoint. You have never said that they are. It was me who made the supposition. Please ask the question correctly.
> 2) A record is inserted into IMR. Nothing gets inserted into RMI and
> into I.
The same probleme with the question.
> 3) A record is inserted into I. Nothing inserted into RMI and into IMR.
> 4) Any superposition of 1-3.
The same probleme.
>> > "Suppose we insert 'JanHidders' into the RealPeople" and suppose
> > >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
> > >
> >
> > 'JanHidders' is an impostor and exists in 'i'.
>
> This is impossible:
> RMI, IMR and I are mutually disjoint. Draw a Venn diagramm if you
> aren't convinced.
I do not understand it. Is it that you try to be ironic with the Venn diagram ? You have never said that 'JanHidders' was not an impostor. This is not a legal supposition. Where did it come from ? You must learn to pose questions. The same problem with the statement that realpeople and impostors are disjoint. Where did it come from ?
>
> What you might want to do is to consider additional cases:
>
> 5. Delete record from RMI and insert it into I.
>
The view is not delete updatable. How do you decide from what table to delete ? One can not decide.
>
> Keep in mind that I considered only one case. Yet whatever transaction
> on tables RealPeople and Impostors you perform, knowing how is
> reflected on RMI, IMR and I sets is sufficient for translating it back
> to base tables.
This remark can be correct but the transactions are not connected to your questions. Do you want to talk about transacions ? We can talk about them, also.
-- TegiReceived on Wed Nov 08 2006 - 22:28:35 CET