Possible Duplicate:
How in .Net do I Import Values from a CSV in the format I want using OleDB?
I have a csv file which I read using OleDbCommand.
The CSV contains columns that are numbers that are left padded with 0. When I read the columns, I get the results without any leading 0 characters: It is now a number.
These values in the CSV:
UserNumber LocationNumber
00001234 00023456
00891234 00000456
becomes
UserNumber LocationNumber
1234 23456
891234 456
In the resulting datatable filled by my OleDbDataAdapter.
Is there any way to prevent this?
PS, Padding is not an issue, but due to the nature of the work being done, not really a good solution as the CSV files have no set format.