COMPUTER SCIENCE AND ENGINEERING
SQL
Question
[CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
|
|
CREATE CARTESIAN PRODUCT
|
|
GET A SYNTAX ERROR
|
|
0 RECORDS RETURNED
|
|
DELETE ALL
|
Detailed explanation-1: -Any JOIN without an ON clause is a CROSS JOIN. The LEFT JOIN is an outer join, which produces a result set with all rows from the table on the “left” (t1); the values for the columns in the other table (t2) depend on whether or not a match was found.
Detailed explanation-2: -You can replace the JOIN keyword with a comma in the FROM clause. What do you do next? There’s no ON keyword for you to state the joining condition as there would be when using JOIN, e.g., on which two columns you want to join the tables. In this method, you simply use a WHERE clause to do so.
Detailed explanation-3: -We can use ‘cross join’ without on condition. Cross join gives the result in cartesian product form. For instance, if in one table there are 3 records and another table has 2 records, then the first record will match with all the second table records. Then, the same process will be repeated for second record and so on.
Detailed explanation-4: -What is a Cartesian join in SQL? The CARTESIAN is also called CROSS JOIN. And in a CARTESIAN JOIN, there exists a join for every row of a table to every row of some other table. It usually occurs when the matching column isn’t specified on when the WHERE condition isn’t specified.