I have a test.csv like so:
83451031,2019-07-04,0,0,0,0,--,0,--,0,0,0,,,,--,--,--,--,--,--,--,--,,,,,,,,,,
1730632031,2019-07-05,0.6023,3200000,0.1789,0.1768,June,0.0097,5,381.1,515.4,46300,11.67,68.97,19.36,4.33,67.51,22953,49,0.0053,Typical,8.3,377,,--,--,,--,--,,--,--,
I want to replace --
with nothing i.e. blank
I've tried the following:
$ sed 's/--/' test.csv > test.csv
$ sed -i 's/--/' test.csv
$ sed -i "s/--/" test.csv
$ sed -i "s/--//" test.csv
$ sed -i "s/--//g" test.csv
$ sed -i "s/'--'//" test.csv
$ sed -i "s/'--'//g" test.csv
$ sed -i "s/'--'/''/" test.csv
All of which gives an error of:
sed: 1: "test.csv": undefined label 'est.csv'
Since --
signifies the end of command options, I assume that's the problem?
I just want to be able to replace all occurrences of --
in the CSV to blank.