SQL OUTER JOIN – Quiz

For each question below, select the best answer. To select the best answer, click on the circle located on the left of this answer. When all questions are answered, click on the Submit button.

Question 1

Consider the fragment “from clients as cl left outer join salespersons as sa”:
clients is the right table, salespersons is the left table.
clients is the left able, salespersons is the right table.
both clients and salespersons are left tables.
cl is the right table, sa is the left table.

Question 2

For which of the following fragments, clients without salesperson will be displayed:
right outer join salespersons as sa
left outer join salespersons as sa
inner join salespersons as sa

Question 3

For which of the following fragments, salespersons without client will be displayed:
right outer join salespersons as sa
left outer join salespersons as sa

Question 4

For which type of join you can see non matching elements from both tables?:
right outer join
left outer join
full outer join
inner join

Question 5

Can a left outer join show more rows than a full outer join?:
Yes.
No.
It depends.

Question 6

Will a left outer join show more rows than an right outer join?:
Yes.
No.
It depends.

Question 7

Can an inner join show more rows than a full outer join?:
Yes.
No.
It depends.

Question 8

Consider the fragment “salespersons as sa on cl.salesperson_id = sa.id”. Which of the following is true:
On left outer join, we cannot see a row in the clients table for which salesperson_id is null.
On right outer join, we cannot see a row in the clients table for which salesperson_id is null.
On full outer join, we cannot see a row in the clients table for which salesperson_id is null.

 

 

Once you have completed the quiz, calculated your score and reviewed your answers, I invite you to go to the next lesson: SQL group by.
 
Share on:

Something not clear? Ask your question here:

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

 
 

Author:
Last udpated: September 10, 2017
Created: September 2, 2014