Table Partitioning: Exploring Partition Level Operations

follow ALTER INDEX [PK_indexname] ON [tablename] REBUILD PARTITION = ALL WITH (ONLINE= ON);

source ALTER INDEX [PK_indexname] ON [tablename] REBUILD PARTITION = 1 WITH (ONLINE= ON);

go