crackyourinterview.com


To improves our performance please Like Share Subscribe(Will boost us)

Write down difference in between Inner Join and Outer Join?
Question Posted on 17 Sep 2023Home >> DataBase >> sql questions >> Write down difference in between Inner Join and Outer Join?

Write down difference in between Inner Join and Outer Join?
Below are the some of the most common different in between Inner and Outer join:-
0
0

Base of differenceInner JoinOuter Join
VariantWhen we say about the Inner join there is no variantsAnd when we say about the variant in Outer join we have two variant that are Left outer or right outer join.
RecordsWhen we say about the records here we have common records from both the tables and one condition is there is there must have some common Id.And when we say about the Outer join we have all entries from the table are taken and there we not required the common Id.
Rows or entriesAll the rows or entries will have values as it is taken from the tables with common entries.All the rows or entries will not have values and return null value as tables with common ID is not necessary.
Use of optimizerWe can use optimizer in inner join as it gives many options.And when we say about the optimizer it is limited as the joins take all the entries and its usage is not feasible.
Used whenWe use inner join when we have the related data entry should exist as per the customer requirement or database design, use inner join.We use outer join when we have a related data entry existence is not necessary, as per the customer requirement or database design, use outer join.
OptionInner join is the common join and is used judiciously. The results provided have least entries and in most cases, will be able to update the requirement of the user.Outer join has many options such as left and right join and hence its usage must be monitored and the results must be checked thoroughly.
PerformanceWhen we say about the performance Inner join are much slower which is not up to mark.When we say about the Outer joins especially left outer joins are faster and perform well in most cases.
ConditionWhen we say about the Inner join a condition is given in the inner join query and it is necessary to satisfy the same.When we say about the Outer join a condition is not given in the outer join query and they need not match any conditions.
OutputIf the rows in table A does not have any matching entries in table B, then those entries are not considered for output in the inner join.If the rows in table A does not have any matching entries in table B, then the output will return null values.
Result stateIn Inner Join if the rows in table A does not have any matching entries in table B, then the output will return null values. In Outer join if there is a match in tables, it will check either the condition whether it is given for left or right tables. If the condition is given, the entry is considered accordingly. If no conditions are given, then the full outer join is the output for the same.


.


Most Visited Questions:-

Deep Learning Questions Answers
Below are the different Deep Leaning Questions and answer a More...

Continuous Integration Questions Answers
Below are the 20 odd questions for CI or Continuous Integra More...

Microservices Architecture Questions Answers
Below are the different questions on Microservices Architec More...

Derived relationships in Association Rule Mining are represented in the form of __________.
Derived relationships in Association Rule Mining are repres More...

What is Gulpjs and some multiple choice questions on Gulp
Gulpjs is an open source whihc helps in building Javascript More...




Other Important Questions

Define N in nvarchar and in nchar?

difference between drop and truncate command

difference between procedure and function

different types of databases in sql

Difference Between Update Lock and Exclusive Lock






@2014-2022 Crackyourinterview (All rights reserved)
Privacy Policy - Disclaimer - Sitemap