Click here to Skip to main content
15,041,548 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
Below mentioned scenario I have

Table A
Empid
1
1
2
2
2
3
3
3

Table B
Empid
1
2
3

so what will be total count when using Inner join, left Join and Right join

What I have tried:

I think, Inner join have 9 rows, Left join have 3 rows, right join have 3 rows. Please suggest with explanation.
Posted
Updated 31-Aug-18 6:47am
v2

1 solution

With the sample data provided, all three joins will have nine rows, since there are no rows in either table without a corresponding row in the other table.

Visual Representation of SQL Joins[^]
   

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)




CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900