我有一个这样的文件:
col1×col2×col3
12×"Some field with "quotes" inside it"×"Some field without quotes inside"
我想用单引号替换内部双引号,所以结果将如下所示:
col1×col2×col3
12×"Some field with 'quotes' inside it"×"Some field without quotes inside"
我想这可以用 sed、awk 或 ex 来完成,但我还没有找到一种干净快速的方法。真正的 CSV 文件大约有数百万行。
优选的解决方案是使用上述程序的单线。
提前谢谢了!