May 5, 2010 at 12:52 am
Hi Guys,
I would like to implement SQL partitioning on an existing table in my database. Can someone please assist? I want to create partitions for every month. The articles on google only explains how to create a partition and to create a table as well but does not explain how to do it with an existing table.
Any advice would be appreciated.
Regards
IC
May 5, 2010 at 1:00 am
Basically, you just have to move the indexes.
Take a look at this article by Martin Bell, I think you will find enlightening.
Hope this helps
Gianluca
-- Gianluca Sartori
May 6, 2010 at 5:24 am
It is quite possible and easy task. Basically you need to first decide on what column ( date ) you need to do the partition on your existing table. You also need to map indexes for same. If you looking something like sliding windows scnerio in your partion then below is the document.
May 6, 2010 at 10:30 am
Gianluca Sartori (5/5/2010)
Basically, you just have to move the indexes.
Clustered!!
-----------------------------------------------------------------------------------------------------------
"Ya can't make an omelette without breaking just a few eggs" 😉
May 6, 2010 at 10:47 am
Rebuilding the clustered index into the partition scheme will move the whole table data into the partition scheme.
To keep nonclustered indexes aligned, they also have to be partitioned, at least including the partitioning key fields.
-- Gianluca Sartori
May 7, 2010 at 5:17 am
Thanks...I found this link very helpful.
Viewing 6 posts - 1 through 5 (of 5 total)
You must be logged in to reply to this topic. Login to reply