Answers

Question and Answer:

  Home  Analyst Integration

⟩ Can you describe difference between correlated and non-correlated subquery?

In correlated sub-query, inner query depends upon outer query and executes for each row in outer query. While non-correlated sub query doesn't depend upon outer query and can be executed independently. Due to this reason former is slow and later is fast. BTW, correlated subquery has some nice application, one of them is finding Nth highest salary in Employee table, as seen on previous SQL question as well.

 236 views

More Questions for you: