Forum Discussion
Anonymous
2 years agoNot applicable
Count Increased after Left join
Hello all, I have two tables Cntry, parts In parts there are 30 columns and in cntry only 2 columns. I am doing Left join based on cntry_abb matching column in both tables Left tables is Parts a...
- 2 years ago
Anonymous if you are linking from cntry table to part tables it will increase the count since there are duplicate in part table,
but if you are doing from part table to cntry table then the count of parts table will remain the same. It is very basic thing, not sure what is the confusion here.
parry2k
2 years agoSuper User
Anonymous it will increase the count:
assuming this
cntry table has following records:
USA
Canada
Product table has following records
USA
USA
Canada
Canada
and based on the above if you do a left join you will get 4 records because of duplicate in the Product table.
- Anonymous2 years agoNot applicable
For example
CNTRY TABLE:CNTRY_ABB CNTRY_NAME AU AUSTRALIA SP SPAIN EG EGYPT CA CANADA
PARTS TABLE:CNTRT_ABB PART NUM ID AU 1054 1 AU 1056 2 SP 1057 3 EG 1057 3 CA 1053 4 CA 1052 4
If I am expanding only CNTRY_NAME Column into Parts table for CNTRY_ABB
How the values counts are increasing then...