Database Reference
In-Depth Information
Figure 13.6
The
CONNECT
_ BY_ROOT
Operator.
The CONNECT_BY_ISLEAF pseudocolumn returns a 1 when part of
the CONNECT BY row set, indicating expansion possibilities.
Thus for the
fourth example, in the following query (the result in Figure 13.8), both
instrument number 10 and its child instruments are shown. However, only
instrument 10 has leaves; the other instruments are child rows, and they
have no further children.
SELECT CONNECT_BY_ISLEAF "IsLeaf"
, INSTRUMENT_ID, NAME, SECTION_ID, LEVEL
FROM INSTRUMENT
START WITH INSTRUMENT_ID = 10
CONNECT BY PRIOR INSTRUMENT_ID = SECTION_ID
ORDER BY 4, 2;
Next we look at flashback and versions queries.
13.3
Flashback and Versions Queries
A flashback query literally allows flashing back to the state that data was in
at a previous point in time. Oracle Database 9
allowed AS OF flashback
queries back to a point in time using a timestamp or SCN. Oracle Database
i
Search WWH ::




Custom Search