TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
C# Corner
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Copy Billions of data from One database table to another database table
Venkatesan Jayakantham
Jun 02, 2010
4
k
0
0
facebook
twitter
linkedIn
Reddit
WhatsApp
Email
Bookmark
Copy Billions of data from One database table to another database table
Copy Billions of data from One database table to another database table
:
Copy Billions of data from One database table to another database table by venkatesan prabu On May 15, 2010
I faced a very different scenario, Copy huge amount of data(Billion records) from one database table to another database table. Do I need to consider anything or Just put select * into or Insert Into query for moving the data.?
It's a very good challenging issue. We can think about some possible options for this issue.
1. Change the database property to "Simple recovery model" Else, you ldf file willbe bombarded due to huge transaction.
2. Do not do the transaction as a whole. Instead, do it in batches. This will provide room to SQL Server to process it.
3. Else you can put it in while loop. So that, your records will be processed in batches.
4. If the database is identical except that particular table. In that case, restore the database.
5. We can think about database mirroring to mirror the database.
Cheers,
Venkatesan Prabu .J
Copy Billions of data from One database table to another database table
Next Recommended Reading
Insert Values from One Database Table to Another Database Table in SQL Server