FMT=TabDelimited does not work.
unable to fetch data that is tab delimited from text file using OleDbConnection string as below
using (OleDbConnection con =
new OleDbConnection(@"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + path + @";Extended Properties='text;HDR=YES;FMT=TabDelimited';"))
Even when I have provided FMT=TabDelimited the data fetched is CSVDelimited ie delimited by comma.
This is because of two different types of data present in the column. So dataset loads the first type of all values. That means if you had put the alphanumeric values first and then the numeric rows, so it would have loaded only alphanumeric values. Because alphanumeric values treated as a type of text.
As a resolution you can select the entire column in the excel file and set its Type to Text. Save it and the reload it. This must solve your problem as once i solved it this way.
Hope that helps. Else, let me know.
Can I export to a text file via a query without wrapping quotes around my strings?
Hi, I'm trying to do an export from access into a text file via a query select CustomerName into [Text;FMT=TabDelimited;HDR=NO;DATABASE=C:\Temp\;].CustomerList.txt from Customer0 votes0 answersJamie Alfordon Apr 22, 2016
Changing data types in a column. Numeric to Alphanumeric
I'm trying to read in a .csv file and I'm running into a problem where the "type" of data changes in a column, so most of the data is numeric, but then some values are text. For example: LocationCode0 votes0 answersBrian Fasanoon Oct 28, 2015
Custom delimited text file
if i have multiple custom delimited text file like (comma,vertical bar etc..). i have tried like "Format" = "Delimited(;),(|)" but failed.. Delimited columns Provider=Microsoft.Jet.OLEDB.4.0;Data Sou-1 votes0 answersGutha Shiva Karan Reddyon Jan 21, 2013
Read Tab Delimited Text file using a Schema.ini into an Access database (ADO)
Hi, i am trying to read a Tab-Delimited Text file using a Schema.ini into an Access database (ADO). however, i dont know how to include the Schema.ini file in ADO. the Schema.ini file has: [Sa0 votes0 answerseijaz sheikhon Dec 21, 2010
- Load more posts