In a 32-bit .NET app, I can use this OLEDB connection string to connect to a CSV file via ADO.NET:
'Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\foo;'
or this ODBC one:
'Driver={{Microsoft Text Driver (*.txt; *.csv)}};Dbq=c:\foo'
However there apparently arent 64-bit versions of either the OLEDB Jet drivers or the ODBC text driver.
I could parse the CSV line by line or run the app in 32-bit mode, but ideally I’d just like to find a different driver that runs as 64-bit.
Any ideas?
It’s not a driver, but I’ve been pleased with Sebastien Lorion’s CSV reader. Note that I’ve never used it in a 64-bit environment, but I’m not aware of any compatibility issues.
http://www.codeproject.com/KB/database/CsvReader.aspx