Re: 3 value logic. Why is SQL so special?
Date: 16 Sep 2006 10:22:54 -0700
Message-ID: <1158427374.560043.293690_at_b28g2000cwb.googlegroups.com>
David Portas wrote:
> Chris Lim wrote:
> As Bob already stated, an "outer join" is not really a join. It is
Table1
Table2
> SQL's syntax shortcut for a UNION. Obviously the answer to your
> question depends on the desired result from such a UNION. The user can
> contrive a query to return whatever values are deemed suitable.
A UNION equivalent an LEFT OUTER JOIN BULLSHIT!!!. A LEFT OUTER JOIN is
just SQL miserable way to force a presentation inspired perspective
into design issues that should be regulated by normalization to
preserve integrity. The proof is that you can do a UNION using 2
relations but using LEFT OUTER JOIN when dealing with relations has no
meaning. Consider 2 tables table1(id1, key1) and table2(id2, key2)
1, A
2, B
3, C
8, A
Table1 LEFT OUTER JOIN Table2 on key1 = key2 produces the following view
1, A, 8, A 2, B, NULL, NULL 3, C, 10, C
Table1 UNION Table2 produces
1, A 2, B 3, C 8, A
10, C
So basically stating that UNION = LEFT OUTER JOIN is stating that
1, A, 8, A 2, B, NULL, NULL 3, C, 10, C
=
1, A 2, B 3, C 8, A
10, C
?... Received on Sat Sep 16 2006 - 19:22:54 CEST