Correlated Sub-QueriesWhat are they?
select c.*
from customers c, orders o
where c.custid = o.custid
and o.stat = “OPEN”
select c.*
from customers c
where exists (
select “X”
from orders o
where o.custid = c.custid
and o.stat = “OPEN” )
select c.*
from customers c
where custid in (
select custid
from orders o
where o.stat = “OPEN” )
Previous slide
Next slide
Back to first slide
View graphic version