Insert to SQL Server from a text file

  • Thread starter Thread starter Michael Barrett
  • Start date Start date
M

Michael Barrett

I am using vb.net and want to insert data from a .csv file into a table. I
am looking everywhere but am coming up empty. Can someone be so kind as to
post some sample code for me?

Thank you.

Mike B
 
Use this as your connection string... Driver={Microsoft Text Driver (*.txt;
*.csv)};Dbq=Directory:\YourFolder\;Extensions=csv;

It asks for a Provider, so I used "Provider=Microsoft.Jet.OLEDB.4.0;" and it gives me the "Can't find Installable ISAM" error.
 
Back
Top