Sub-Queries in Oracle SQL
Sub-Queries in Oracle SQL SNO Type of Sub-Quries 1 Single-Row Sub-Queries 2 Multi-Row Sub-queries 3 Co-Related Sub-Queries 4 Inline Views 5 Scalar Sub-Queries Single-Row Sub-Queries Returns one value SELECT <columns> FROM <table_name> WHERE <col_name> <OP> (SELECT STMNT); > , >=, <, <=, =. <> A single-row subquery in Oracle SQL is a subquery (a query nested inside another query) that returns only one row. Ø It can be used in Select, Where, and Having clauses. Ø The main/outer query uses the inner query result as its conditions. Ø If a single-row sub-query returns more than one row, then you will get an error Ø ORA-01422: exact fetch returns more than the requested number o...