Database Reference
In-Depth Information
Figure 13-8. Representation of a PARTITION RANGE INLIST operation
Of course, if the values in the IN condition are sufficiently spread, it's possible that most of the partitions are
accessed. In cases where the query optimizer recognizes that all partitions are accessed, the operation in the next
section applies.
PARTITION RANGE ALL
If no restriction is applied to the partition key, all partitions must be accessed. In such a case, the execution plan
contains the PARTITION RANGE ALL operation, and the Starts , Pstart , and Pstop columns clearly show that all
partitions are accessed:
SELECT * FROM t WHERE n3 BETWEEN 6000 AND 7000
-------------------------------------------------------------
| Id | Operation | Name | Starts | Pstart| Pstop |
-------------------------------------------------------------
| 0 | SELECT STATEMENT | | 1 | | |
| 1 | PARTITION RANGE ALL | | 1 | 1 | 48 |
|* 2 | TABLE ACCESS FULL | T | 48 | 1 | 48 |
-------------------------------------------------------------
2 - filter(("N3">=6000 AND "N3"<=7000))
This very same execution plan is also used when inequalities are used as restrictions on the partition key.
The following query is an example:
SELECT * FROM t WHERE n1 != 3 AND d1 != to_date('2014-07-19','YYYY-MM-DD')
 
Search WWH ::




Custom Search