This post is the last part of a series that discusses table clustering in Oracle.
- Introduction and Ancient History
- Cluster & Cluster Key Design Considerations
- Populating the Cluster with DBMS_PARALLEL_EXECUTE
- Checking the Cluster Key
- Using the Cluster Key Index instead of the Primary/Unique Key Index
- Testing the Cluster & Conclusion (TL;DR)
Testing
We did get improved performance with the clustered tables. More significantly, we encountered less inter-process contention, and so were able to run more concurrent processes, and the overall elapsed time of all the processes was reduced.
Looking at just the performance of the bulk delete statements on the result tables, there is a significant reduction in DB time and physical I/O time on the clustered tables. The reduction in physical I/O is not only because the table is smaller, but because there is no need to perform consistent read recovery on the blocks, there are fewer reads from the undo segment and less CPU was consumed creating consistent read copies in the buffer cache.
Statement | Heap Table | Clustered Table | |
DELETE FROM PS_GP_RSLT_ACUM… | |||
DB Time (s) | 2182 |
1662 | |
delete statement only | db file sequential | 1451 |
891 |
CPU | 941 |
531 |
Statement | Heap Table | Clustered Table | |
DELETE FROM PS_GP_RSLT_ABS… | |||
DB Time (s) | 781 |
330 | |
delete statement only | db file sequential | 340 |
210 |
CPU | 300 | 120 |
Statement |
Heap Table | Heap in Cluster Test | |
DELETE FROM PS_GP_RSLT_PIN… | |||
DB Time (s) | 270 |
250 | |
delete statement only | db file sequential | 110 |
120 |
CPU | 110 |
90 |
No comments :
Post a Comment