Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> SQL QUESTION:How did correlated subquery process?

SQL QUESTION:How did correlated subquery process?

From: Cantonese Boy <waynewan_at_yahoo.com>
Date: Tue, 21 Aug 2001 22:00:05 +0800
Message-ID: <3B826965.46CC256A@yahoo.com>


Hi:

	Quoted from a book:
		"A correlated subquery is evaluated once for each 
		 row processed by the parent statement."

	I'm not very sure what does it exactly mean. Does it mean
	every row selected from the parent statement will
	pass to the subquery to process?

	For example, if what I think was right ,why the follow DML
	won't remove all the row in the emp table ?

	delete from emp e
	where sal = (select max(sal) from emp
		     where deptno= e.deptno);


	Can someone tell me how oracle will process this statement.


Thank you

W. Received on Tue Aug 21 2001 - 09:00:05 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US