Information générale
Catégorie:
Codage, syntaxe et commandes
Hi Agnes,
--------
Fabio,
the proble is in (scematic)
From CurA;
inner join CurB on CurA CompareWith CurB;
inner join CurC on CurA CompareWith CurC
Since you join CurC with CurB and the Result with CurA
you may run into problems if you compare at CurC joins ON clause with CurA.
--------
you write this (CurC*CurB)*CurA as righ to left order joining, but without parenthesis not there and an order.
for multiple inner joins :
(CurC*CurB)*CurA == CurC*(CurB*CurA) == (CurA*CurC)*CurB ...
---------
What I have done is to modify the SELECT SQL in a way the the cursors on both "sides" of JOIN are used in the on clause.
I have had problems like that with outer joins and I'm not sure what happens in plain inner joins, but to me it's a good idea to do things in a way that works everywhere.
For me this is not a good choice.
T1 INNER T2 ON condition(T1,T2) WHERE filter(T1,T2)
and
T1 INNER T2 ON condition(T1,T2) AND filter(T1,T2)
are equivalent respect to the set algebra,
but are not semantic equivalent !
For me, the SELECT it must express the semantic request!
For Outer joins set algebra have minor theoremes and invariances,
and associative invariance is not true, and ON have a specific logic.
Have nice weekend also to you.
Fabio
Précédent
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement