MCQ IN COMPUTER SCIENCE & ENGINEERING

COMPUTER SCIENCE AND ENGINEERING

SQL

Question [CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
Which join would you use to create a query that returns ALL data from Table B and only those on Table A that match?
A
Inner Join
B
Left Join
C
Right Join
D
Full Outer Join
Explanation: 

Detailed explanation-1: -A INNER JOIN B is a combined table and is the answer.

Detailed explanation-2: -A CROSS join returns all rows for all possible combinations of two tables. It generates all the rows from the left table which is then combined with all the rows from the right table. This type of join is also known as a Cartesian product(A*B).

Detailed explanation-3: -INNER JOIN statement returns only those records or rows that have matching values and is used to retrieve data that appears in both tables.

Detailed explanation-4: -The FULL OUTER JOIN keyword returns all records when there is a match in left (table1) or right (table2) table records.

There is 1 question to complete.