• cj_logan (5/27/2009)


    Question

    Why is the inner join the recommended option ? I know Microsoft recommends this way but no where can I find a reason ? According to the execution plan both are the same and both cost 50%

    SELECT t1.en [Em], t2.en [Ma] FROM E t1, E t2 WHERE t1.mid = t2.eid

    order by t1.en

    SELECT t1.en [Em], t2.en [Ma] FROM E t1 inner join E t2 on t1.mid = t2.eid

    order by t1.en

    Joins in ANSI syntax can be made explicit without mangling the where logic. Parsers and optimizations have less ambiguity to deal with under certain conditions. The old syntax of using *= for left and right joins can now be done away. Cross joins also become explicit. For programming, the cleaner and more explicit ANSI syntax could lead to faster debugging. It took me a while to transition, but now that I did, I like it.