SQLTeam.com | Weblogs | Forums

Move partitioned table to a new filegroup


#1

Hi,

if you want to just move the table to a new filegroup, you need to
recreate the clustered index on the table (after all: the clustered
index is the table data) on the new filegroup you want.

CREATE CLUSTERED INDEX CIX:Table
ON dbo.Table(ClusteringKeyFields)
WITH DROP_EXISTING
ON [newFilegroup]

Question: Can we do this with a partitioned table also? (We don't need any Partition for this table)

Regards
Nicole


#2

IIRC All tables have at least one partition, even if they are not defined as partitioned!

Questions:

  1. have you tried to do the move? IF so, did it work? If it didn't work, what error did you get?
  2. Are you asking about moving a partitioned table to a non-partitioned table? Yes, that should work,