I have a very large data file with around 60000 rows. I need to split the CSV file based on columns into different arrays for each column.
I have 5 columns; State, County, Zipcode, Latitude, Longitude.
How would I, when I read the file, split it and add them in order to each array?
I would have an array for State, County, Zipcode, Latitude, and Longitude.
Use a CSV parser – there are plenty for .NET, even a built in one in the
VisualBasicnamespace.See
TextFieldParser– though in theVisualBasicnamespace, it is a regular .NET library that can be used by any .NET language.There are many other options.