Quantcast
Channel: Microsoft SQL Server
Viewing all articles
Browse latest Browse all 4871

Difficulties exporting very large file in SQL

$
0
0

Using Bulk insert, I used the following code (repeated many times) to put all of the data into one collection

Text
bulk insert equi From 'C:\Users\someone\Desktop\Equi_import\xyz.NV184' WITH (FORMATFILE = 'C:\Users\someone\Desktop\formatfileequi.txt' ); 

When I attempt to export it and place it in another database, I notice that each row is not self contained. Example below

122222abc

It appears as such

122222abc cr-lf

cr-lf

133333abc cr-lf

cr-lf

I know that the cr means carriage return and lf denotes line feed.

As for the formatfile, the last two fields mentioned are catch-all's. they are titied Nothing Char (261) and blank char(3).

The bulk insert works fine but when I export it, it seems to be placing an additional CR-LF in there, What can be done about that?


Viewing all articles
Browse latest Browse all 4871

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>