Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 Creating an index

Author  Topic 

Bill_C
Constraint Violating Yak Guru

299 Posts

Posted - 2009-03-26 : 09:46:17
I am importing data from an external source and am creating a table to contain the data.
Is it better to create a unique clustered index on the table BEFORE I populate the table or AFTER?

darkdusky
Aged Yak Warrior

591 Posts

Posted - 2009-03-26 : 10:04:51
http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=121345
Go to Top of Page

Bill_C
Constraint Violating Yak Guru

299 Posts

Posted - 2009-03-26 : 10:12:00
Thanks, but I'm still a little puzzled over what approach to take, my table holds well in excess of 100 Million rows.
Go to Top of Page

Bill_C
Constraint Violating Yak Guru

299 Posts

Posted - 2009-03-26 : 10:41:32
Reading through again, it looks like option 2 for me then, thanks.
Go to Top of Page

darkdusky
Aged Yak Warrior

591 Posts

Posted - 2009-03-26 : 11:40:12
Here's a link to demo of import using table partitioning as part of import process:
http://blog.sqlauthority.com/2008/01/25/sql-server-2005-database-table-partitioning-tutorial-how-to-horizontal-partition-database-table/

Partitioning should minimise the impact on the rest of the database during the import.
Go to Top of Page
   

- Advertisement -