Conversation
Notices
-
@spandexbob @k4k this is a example line with four fields: name,"street,city",country,phone Problem is field 2: "street,city"
-
@theloser python is pretty good at handling csv files, do you have a target language?
-
@theloser something like this http://bit.ly/nyMkXt will simply parse a csv file in python
-
@spandexbob It's a korn shell script on AIX ;-)
-
@theloser A bit ugly but you could do sed -e 's:,:+++:g' -e 's:+++ :, :g' -e 's:+++:;:g' assuming +++ does not naturally appear ..
-
@theloser .. anywhere else
-
@theloser or better yet just sed -e 's:,:;:g' -e 's:; :, :g' should work if there are no semi-colons in the original file.
-
@spandexbob Urks. I need that "quotechar" option for the 'cut' command in korn shell ;-)
-