Appending line ending with '}" to new line

Hello masters.

I have a rather simple problem but its been killing me. I have a file "x" with only 1 line inside it. The line looks something like

Now this is only part of the line. Its actually about 4000 characters. What i need to do is whenever there is a "}", i need to append the next characters into a new line. Ive tried cracking my head with sed but cant find the correct command. Pls help. I need something that will look like

01|15131|2506
01|15651|2506
01|20831|2506
01|24811|2506

Pls HELP !

Thanks.
Sara

Try

tr '}' '\n' < your_file| tr -d '"{'

or

cat your_file | tr '}' '\n' | tr -d '"{'

Or,

sed -e "s/}/}\n/g" in.txt

To get the output you are looking for, i.e.

01|15131|2506
01|15651|2506
01|20831|2506
01|24811|2506

use

sed -e "s/}/}\n/g" -e "s/[\"{}]//g" -e "s/|\n/\n/g" in.txt

Thanks lorcan, it works beautifully. Wish i were as good as you guys. :slight_smile:
Thanks again

Thanks vino. But its giving me an output like

however i already have the solution. Thanks guys.