Can anybody give the best exaplanation for the diffrence between sub-query and nested query?
Can anybody give the best exaplanation for the diffrence between sub-query and nested query?
As grant says, the things you have mentioned are one and the same.
You basically have:
A sub-query - this is a query which is used as part of a larger query. Much as you would select from a table, you can select from a sub-query.
A correlated sub-query - this is a particular type of sub-query that references the outer query - it's used for exists, having etc.
A scalar sub-query - this is where you use a sub-query more like a column - to pick up a single value from somewhere.
Hope that helps...
No one has followed this question yet.