I am trying to import a .csv file into a SQL Server database without the headers.
.csv
This code works fine, but with headers - how can skip the headers? What do
Just ignore the headers when you read the data from the file. Delete these lines:
string[] headerColumns = header.Split(','); foreach (string headerColumn in headerColumns) { importedData.Columns.Add(headerColumn); }