November 8, 2016 at 2:45 pm
Hello,
I am stuck in a 4GB text file import and it stops with 2870269 imported, in order to find out the reason of the showstop, I use EmEditor to open the actual raw data file, it is found that lines after 2870269 were also imported, so my question is:
Does the SQL Import wizard imports data in sequence?
It doesn't seem yes according to my finding but how can I find the problematic line?
Thank you very much.
November 8, 2016 at 3:42 pm
Yes it will process text files in line order, that is no guarantee however that they'll come out of a database table in that order. The line counter can also be somewhat twitchy with large row counts, especially if it crashes while processing. You might be able to try loading from your text file into another text file and seeing where/if it crashes doing that.
November 8, 2016 at 11:25 pm
ZZartin (11/8/2016)
Yes it will process text files in line order, that is no guarantee however that they'll come out of a database table in that order. The line counter can also be somewhat twitchy with large row counts, especially if it crashes while processing. You might be able to try loading from your text file into another text file and seeing where/if it crashes doing that.
If you do it with BULK INSERT, an IDENTITY column, and a MAXDOP(1) setting, I can see no reason why it would go out of order.
--Jeff Moden
Change is inevitable... Change for the better is not.
November 9, 2016 at 6:43 am
Jeff Moden (11/8/2016)
ZZartin (11/8/2016)
Yes it will process text files in line order, that is no guarantee however that they'll come out of a database table in that order. The line counter can also be somewhat twitchy with large row counts, especially if it crashes while processing. You might be able to try loading from your text file into another text file and seeing where/if it crashes doing that.If you do it with BULK INSERT, an IDENTITY column, and a MAXDOP(1) setting, I can see no reason why it would go out of order.
That's true, but unfortunately for most of the imports the approach would be using the wizard to get data in place as soon as possible.
BTW, can anyone recommend a good non-SSIS ETL tool for MS SQL? Thanks.
November 9, 2016 at 7:30 am
halifaxdal (11/9/2016)
Jeff Moden (11/8/2016)
ZZartin (11/8/2016)
Yes it will process text files in line order, that is no guarantee however that they'll come out of a database table in that order. The line counter can also be somewhat twitchy with large row counts, especially if it crashes while processing. You might be able to try loading from your text file into another text file and seeing where/if it crashes doing that.If you do it with BULK INSERT, an IDENTITY column, and a MAXDOP(1) setting, I can see no reason why it would go out of order.
That's true, but unfortunately for most of the imports the approach would be using the wizard to get data in place as soon as possible.
If you want to "get data in place as soon as possible", avoid the manual labor and error prone tendencies of the wizard.
BTW, can anyone recommend a good non-SSIS ETL tool for MS SQL?
If the data files are of good quality in their structure, I just did. 😉 If the data files are of unpredictable/questionable structure, then a pork chop launcher and an up-close and personal visit to the people providing the data files is in order.
--Jeff Moden
Change is inevitable... Change for the better is not.
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply