I have a text file with following data and each row ends with |END|
.
T|somthing|something|END|T|something2|something2|END|
I am tryig to replace |END|
with \n
new line with sed.
sed 's/\|END\|/\n/g' test.txt
But it's producing wrong output like below:
T
|
s
o
m
e
...
But what I want is this:
T|somthing|something
T|something2|something2
I also tried with tr
. It didn't work either.