• sqlfriends (11/9/2011)


    so if I change the join to cross join and take off 1=1, it will be the same, correct?

    But I read somewhere if a cross join have a where clause, it is the same as inner join,

    is it true for this case?

    Thanks

    You can produce CROSS join with any of the following:

    select a.*, b.*

    from a,b

    select a.*,b.*

    from a CROSS JOIN b

    select a.*,b.*

    from a INNER JOIN b

    on 1=1 -- fake condition to satisfy INNER JOIN syntax.

    The results would be same until you add any filters.