In Oracle 10g I'm creating a range partitioned table. Each partition will be a year. My question is what do you use for the name of the MaxValue partition? I was planning to call my partitions P2001, P2002, P2003 ... P2009. Suggestions welcome, I've considered P9999, PCurrent, PThisYear, PFuture, PEmpty, PMaxValue, and PCreateAnotherPartition.
-
We've used
FY2002_PART, FY2003_PART, etc.Truly, the only obvious suggestion would be to name it something that makes sense to you and your group (and future maintainers) ... Its all in the usage!
Leigh Riffel : Well, they all make sense to me now, but I'm not sure they will later. I'm particularly interested in what to name the MaxValue partition, but thanks for letting me know the partition names you use.From curtisk -
I like the P9999 idea, as it keeps the same length. Also, you get the same order whether you sort by partition_name or partition_id.
Some people prefer to add a prefix that indicates the table name as well (length is an issue). Say your table is called TABLE1, then your partitions could be called TABLE1_2008, TABLE1_2009, TABLE1_9999, etc, as it makes the names unique for the whole schema.
But it's only a matter of preference. In Oracle 11g you can have interval partitions, and then it's the database choosing the name of the partitions, and those won't be pretty.
From Pop -
I call mine P_DEFAULT
From WW
0 comments:
Post a Comment