InterviewSolution
Saved Bookmarks
| 1. |
What is a Cross-Join? |
|
Answer» CROSS join can be defined as a cartesian product of the two tables INCLUDED in the join. The table after join contains the same number of rows as in the cross-product of the number of rows in the two tables. If a WHERE clause is used in cross join then the query will work like an INNER JOIN. SELECT stu.name, sub.subject FROM students AS stuCROSS JOIN subjects AS sub; Write a SQL statement to CROSS JOIN 'table_1' with 'table_2' and fetch 'col_1' from table_1 & 'col_2' from table_2 respectively. Do not USE alias. CHECK Write a SQL statement to perform SELF JOIN for 'Table_X' with alias 'Table_1' and 'Table_2', on columns 'Col_1' and 'Col_2' respectively. Check |
|