Oracle FAQ Your Portal to the Oracle Knowledge Grid

Home -> Community -> Mailing Lists -> Oracle-L -> Partitioning Question and FKs to Non-Partitiond Tables

Partitioning Question and FKs to Non-Partitiond Tables

From: david wendelken <>
Date: Thu, 25 Mar 2004 15:55:39 -0500 (GMT-05:00)
Message-ID: <>

I've been working thru partitioning issues and have a question on a specific topic.

Guidance would be more than welcome!

FACT) I have a natural way to partition many of the data tables in the application. I have a partitioning data column in those tables. I'll call it segment_value and it's part of the natural primary key. There's no other reasonable way to partition things that would also make sense from a maintenance perspective.

FACT) However, segment_value is not particularly unique, the other primary key column in the partitioned tables is unique by itself. So, I've put segment_value as the second column of the primary key, not the first column.

BELIEF) I think that was a good thing to do. But I could be wrong.

FACT) Some reference tables should not be partitioned because, well, they shouldn't be. They are used equally across all partitions.

SAD FACT) I will need to load, flush, and re-load some partitions. The exchange option looks promising for this.

SAD FACT) I'm short-handed on my project and short on schedulable down-time, too.

BELIEF) Local indexes on partitioned tables make it easier to take care of the above sad fact, with minimal impact on people making use of the other partitions. Global indexes slow some maintenance activities down.

CONCLUSION) Use local indexes where possible.

When I do an FK from a partitioned table to a non-partitioned table, it won't have segment_value in the primary key. So, the FK index wouldn't naturally have segment_value in it. That would seem to make it a global index.

Any way out of this, to end up with local indexes? I haven't (yet) tried to see if I can get away with stuffing segment_value on the back of the same index used by the foreign key and partition by that. Not a lot of hope, but I might get lucky. Any comments before I spend the time to test out the idea?

Please see the official ORACLE-L FAQ:

To unsubscribe send email to: put 'unsubscribe' in the subject line.

Archives are at FAQ is at
Received on Thu Mar 25 2004 - 14:58:29 CST

Original text of this message