Oracle

Subquery Syntax

Figo Kim 2006. 9. 1. 20:15
SELECT select_list
FROM table
WHERE expr operator
(SELECT select_list
FROM table);
  • The subquery(inner query) executes once before the main query(outer query).
  • The result of the subquery is used by the main query.

You can place the subquery in a number of SQL clauses, including the following:

  • WHERE clause
  • HAVING clause
  • FROM clause