Solved

bluk insert skip header

Posted on 2004-09-16
1
593 Views
Last Modified: 2012-05-05
I want to do a bulk insert on a csv file the problem is the file will always have a header how do i skip the header (1st line) and read in the rest of the docs.
0
Comment
Question by:running32
1 Comment
 
LVL 10

Accepted Solution

by:
Jay Toops earned 125 total points
ID: 12077274
youd use the firstrow parameter

example

BULK INSERT tmpTable1 FROM 'c:\InputFile.csv' WITH (FIRSTROW=2, FORMATFILE='c:\FormatFile.txt');

Jay
0

Featured Post

Complete VMware vSphere® ESX(i) & Hyper-V Backup

Capture your entire system, including the host, with patented disk imaging integrated with VMware VADP / Microsoft VSS and RCT. RTOs is as low as 15 seconds with Acronis Active Restore™. You can enjoy unlimited P2V/V2V migrations from any source (even from a different hypervisor)

Join & Write a Comment

International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
Via a live example, show how to extract information from SQL Server on Database, Connection and Server properties
Viewers will learn how to use the SELECT statement in SQL and will be exposed to the many uses the SELECT statement has.

706 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now