0

I'm trying to replace a csv delimiters using regular expression, but can't get my head around the parameters.

Sample text:

2136203,"asd asdd","17 - Alpha","13 - Scsdeori Colsden",05.04.12,A,255659,"VOSDEFER ADEDEAN","SER.HDEDEA NR 52 BL - SC - AP -, PDEXTA, AEDD, CP 312337",RO26A34498,20.04.12,,12.04.12,"Confsdare"

I want to split the string like this:

  1. 2136203
  2. asd asdd
  3. 17 - Alpha
  4. 13 - Scsdeori Colsden
  5. 05.04.12
  6. A
  7. 255659
  8. VOSDEFER ADEDEAN
  9. SER.HDEDEA NR 52 BL - SC - AP -, PDEXTA, AEDD, CP 312337
  10. RO26A34498
  11. 20.04.12
    1. 12.04.12
  12. Confsdare
XandrUu
  • 1,169
  • 4
  • 26
  • 46

1 Answers1

1

Use the example on the top answer here to parse the file.

This turns your file into a string[] you read one row at a time.

Then write out a new file with the format you need.

Community
  • 1
  • 1
jonathanpeppers
  • 26,115
  • 21
  • 99
  • 182