How to split csv whose columns may contain ,

前端 未结 8 1311
我寻月下人不归
我寻月下人不归 2020-11-22 06:35

Given

2,1016,7/31/2008 14:22,Geoff Dalgas,6/5/2011 22:21,http://stackoverflow.com,"Corvallis, OR",7679,351,81,b437f461b3fd27387c5d8ab47a293d35,34

8条回答
  •  被撕碎了的回忆
    2020-11-22 07:22

    You could split on all commas that do have an even number of quotes following them.

    You would also like to view at the specf for CSV format about handling comma's.

    Useful Link : C# Regex Split - commas outside quotes

提交回复
热议问题