Currently we have SQL scripts which import all data into ONE COLUMN Table
using bulk Insert statement and then from there we use SUBSTRING Function to
sort data into our main tables. Now we are developing VB.NET application
which will insert data directly into main Tables.
Performance is the main concern now, because VB.Net application taken twice
the amount time as SQL Script used to take.
I have following questions:-
1- Is there any way I can stop Transaction log (we are using simple
recovery) so data could be inserted more rapidly?
2- What should be the idea size of Tempdb, data and log file so its don’t
have to grow over and over during the insert? (for 30 GB total data needs to
insert)
3- Can I use DTS package and combine Transform and bulk insert operation
together in one step instead of two steps?
4- Is there any thing else I can do to reduce the insert or import time?
(currently its taking 90 minutes when we use SQL Scripts for 6 GB file and
200 minutes when we use VB.NET application)
5- What will be the ideal time for such kind of huge import?
Thank you for your help.
Regards,
-Permood
"Permood" <Per...@discussions.microsoft.com> wrote in message
news:9A78306D-2C7F-46B2...@microsoft.com...
Better to use yyyymmdd (see convert in BOL, style 112), and sql server will
understand them no matter the settings of "SET DATEFORMAT" and language
currently being used.
> I need to insert 60 millions records or 6GB Fixed width text File into SQL
Why are you importing the data into just one column?, you can use DTS to
load fixed width file format an map the data into diff columns.
> 1- Is there any way I can stop Transaction log (we are using simple
> recovery) so data could be inserted more rapidly?
No matter if you use DTS, BCP or BULK INSERT to import the data, the idea is
to do it in batches and not in one huge batch. For example, if you are using
BULK INSERT then take a look to read about ROWS_PER_BATCH argument.
> 3- Can I use DTS package and combine Transform and bulk insert operation
> together in one step instead of two steps?
If you follow this approach then it will be like processing the batch one
row at a time (not exactly but similar, I think). If you upload the data into
an Intermediate table, then you can use set-based operations to route the
data to the corresponding tables. Anyway you should test both approach two
see which one give better performance.
AMB
Is there any thing else i can do to make this process faster?
once again thanks for your time and help.
"Permood" <Per...@discussions.microsoft.com> wrote in message
news:6AF25AFC-8C20-477D...@microsoft.com...