T-Virus
asked on
Bulk Insert Row Terminator
Hi,
i got a flat file which i would like to Bulk insert into a table
Flatfile Format
So the problem that i have is, that Bulk insert is only looking for the row terminator in the last column.
So the table would look like this:
col1 col2 col3 col4 col5
1 2 3 4 5
1 2 3 4 1
Instead of
col1 col2 col3 col4 col5
1 2 3 4 5
1 2 3 4
1
Is there a way to give the row terminator a higher priority or something?
I guess i would have the same issue with xml format files.
i got a flat file which i would like to Bulk insert into a table
Flatfile Format
1,2,3,4,5/n
1,2,3,4/n
1/n
So the problem that i have is, that Bulk insert is only looking for the row terminator in the last column.
So the table would look like this:
col1 col2 col3 col4 col5
1 2 3 4 5
1 2 3 4 1
Instead of
col1 col2 col3 col4 col5
1 2 3 4 5
1 2 3 4
1
Is there a way to give the row terminator a higher priority or something?
I guess i would have the same issue with xml format files.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
I do know tools that where written in java that would work trough the exact same flatfile in less then 5sec. (2mil rows)
So in your opionion which way is the fastest?
Some Script that would do the job before Bulk inserting the data or
this Function? Even if the Function would take 30min to transform the date into a new table not faltfile funnily, there it would take just 5sec. But is it really the way to go with import export import?
Open in new window