[SOLVED] replace \n with space in csv file
by sag2662 from LinuxQuestions.org on (#6EN9V)
Hi all, I have csv file with the some of the rows with "\n" values, and I wanted to replace "\n" with just empty space " ". How can i achieve it. I tried the below but doesnot work. can anyone help?
Code:sed 's/\/n/ /g' "$input_file" > "$output_file"my csv file looks like this
Code:Name,Age,Location
Alice\nbhat,25,New York
Bob\n,30,Los Angeles
Charlie\nTC,22,Chicago
Code:sed 's/\/n/ /g' "$input_file" > "$output_file"my csv file looks like this
Code:Name,Age,Location
Alice\nbhat,25,New York
Bob\n,30,Los Angeles
Charlie\nTC,22,Chicago