Skip to Main Content

Oracle Database Discussions

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Lengthy Query Time on an Empty Partition

Paul V.Apr 20 2015 — edited Apr 20 2015

DB: 11.2.0.3

OS: Linux, kernal 2.6.18

I have a large partitioned table that contains XML documents stored in a clob column.  Aside from the clob column there are 15 other columns (varchar, numeric or date) in the table. Each partition has a tablespace for the clob column and a tablespace for the other columns.

Table Partitions: 28

Table Rows: 590,000,000

Table Size: around 20 TB with 95% of that found in the column LOB Column

Two of the partitions are currently empty.  One has never had any records inserted into it, the other at one time had 40,000,000 records that were deleted through a series of delete calls (not through a partition truncation). 

When I run a select count(*) statement on each of these two empty partitions, the partition that has always been empty returns immediately.  Same query on the other partition takes 20 minutes to return a count of 0.  I have updated the statistics on the newly empty partition.  The explain plan for both looks the same for the operations but the cost is 197K for the always been empty partition and the cost of the other is 2421K.  Is there something I can do to help Oracle realize that there is the same amount of data in each of these two partitions?

This post has been answered by unknown-7404 on Apr 20 2015
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on May 18 2015
Added on Apr 20 2015
4 comments
1,134 views