I have csv files. I am attaching a sample. Some of the strings are not quoted (most are quoted) but I need every string to be quoted.
I was thinking about how to do this. I thought that I could take any field (a field would seem to be something that was separated by commas) and if it contains any non-numeric data then put quotes around the entire contents.
However that definition of a field does not work since within the string there may be commas and so those commas would also (mistakenly) be considered the delineaters of a field.
So then I though I could first just remove all the commas (I don't need them for any meaning they might give to the string) but this does not work because that would eliminate all the field delineating commas as well.
Does anyone have a strategy for doing this?
The fields that need to be quoted are columns 2, 3, 4, 5, 10