Difference between sub query and nested query ?
Answer Posted / lakshmi
Correlated subquery runs once for each row selected by the
outer query. It contains a reference to a value from the
row selected by the outer query.
Nested subquery runs only once for the entire nesting
(outer) query. It does not contain any reference to the
outer query row.
For example,
Correlated Subquery:
select e1.empname, e1.basicsal, e1.deptno from emp e1 where
e1.basicsal = (select max(basicsal) from emp e2 where
e2.deptno = e1.deptno)
Nested Subquery:
select empname, basicsal, deptno from emp where (deptno,
basicsal) in (select deptno, max(basicsal) from emp group
by deptno)
Is This Answer Correct ? | 96 Yes | 11 No |
Post New Answer View All Answers
Explain cascading triggers.
What privilege is needed for a user to connect to oracle server?
Why is oracle used?
ur a sql devoloper...what is the process in ur company for finding the database BUGS .. seperate DB testers are there? or devr.s are manage? if DB TESTERS in there what is the process
What is a initialization parameter file in oracle?
What privilege is needed for a user to delete rows from tables in another schema?
how do we code triggers , store procedure , Performance tuning and indexing in a Java Project? Pls kindly get me the perfect answer with the code for each....thank you in advance............pls any body kindly help me soon as possible....
What is an oracle database?
What is query image?
What is a view and how is it different from a table?
what is reindexing?
How to get maxsal , minsal, ename department wise in single query
What are the numeric comparison operations?
What is a directory object?
What is the Tune Query