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
 SQL Server 2005 Forums
 Transact-SQL (2005)
 25 millions records insert ,takes more than 3 hrs

Author  Topic 

Rajesh_r_varma
Starting Member

3 Posts

Posted - 2008-05-14 : 09:18:38
Hi Teachies,

I am using SQL Server Standard Edition .

in one of my table , there i am inserting around 25 millions records and that takes time around more than 3 hrs.

same thing is happening while fetching records from that table.

this database contains only single file group i.e primary

and that table contains .. Clustered as well as non clustered index.

it doesnot have any Triggers.

How do i increase this performance.

Paritioning of table cannot be use in SQL Server Standard Edition.

Or Dropping all non clustered index before insert operation will improve my performance.

Please suggest me.

Thanks

Rajesh Varma

SwePeso
Patron Saint of Lost Yaks

30421 Posts

Posted - 2008-05-14 : 09:22:37
On what is the clustered index built upon? Which column?
How do the new records affect the clustered index?

Is this a ine-time operation or a recurring event?




E 12°55'05.25"
N 56°04'39.16"
Go to Top of Page

yosiasz
Master Smack Fu Yak Hacker

1635 Posts

Posted - 2008-05-14 : 14:35:27
that is a good question Peso asks. if it is recurring why do you need to insert so many records * recurring time. what u need is a nice and clean ETL with staging tables. you insert only new records, mark as deleted (DeletedFromSourceYesNo) those that exist in your database but not anymore in source datasource, update existing ones that changed by doing some sort of binary checksum. that is how we do it with nice success.
Go to Top of Page
   

- Advertisement -