Skip to main content

Posts

Showing posts from June, 2010

Cross Join or comma separated tables

In SQL cross join returns the Cartesian product of all tables involved in the join.  For two tables, the resulting number of rows returned equals the number of rows in the first table times the number of rows in the second table. It  can be written using one of the two syntax: SELECT  A.COLUMN1 , B.COLUMN1 , C.COLUMN1  FROM TABLE1 A ,  TABLE1 B  ,  TABLE1 C OR SELECT  A.COLUMN1 , B.COLUMN1 , C.COLUMN1  FROM TABLE1 A   CROSS JOIN TABLE1 B  CROSS JOIN TABLE1 C