Forum Discussion
Salman70
May 10, 2019Copper Contributor
BCP command with a format file to skip a header row issue.
While using BCP command with format file to insert a large file i.e. 7GB in size export to database table without a header row then we unable to insert the first row of data.
I used -F1 and -F2 both in PowerShell command for skipping the header only but both are not working.
The main problem is my header contains only 3 columns and the data is about 13 columns that's why the first record is included with a header.
My sample data is as follows :
HEADER|TAXLOT|20180104
A35972|01859M408|20170109|57.8270|504.84|0|0.00|0.00||0|0|CLSIT1|
A35972|63872T729|20161027|211.3820|2088.46|0|0.00|0.00||0|0|ASXTU5|
A35972|63872T729|20161123|195.3990|1911.00|0|0.00|0.00||0|0|ASXTU5|
A35972|63872T729|20170404|3.8540|38.00|0|0.00|0.00||0|0|ASXTU5|
TRAILER|TAXLOT|20180104|18954837
In this sample data, the record that is in bold is not inserted in the database.
Can anyone please suggest any solution?
No RepliesBe the first to reply