DB2 5 - Useful/Important Queries

Sub-Query:

Query with in a query is defined as sub-query.

Note: In sub-query 1st inner query will be executed, based on inner query result outer query will be Executed.

Ex: Try to retrieve 2nd max salary from below table.

    EMP
NME         SAL
ABC          6000
XYZ          9000
A123         8000
B345         7000


For more details, click on below Video.


Previous
Next Post »