I am using
I have a file
temp.txt with some pipe delimited data.
As clear from example, the record ends with a new line character after the data value in the last column.
However, I want the record to end with a pipe delimiter and a new line character as below:
I tried the following commands but still unsuccessful:
tr '\n' '|\n' < temp.txt
sed -i 's/\n/|\n/g' temp.txt
Am I missing something?