Replace Language Specific Characters in File

Hi Team,

I have requirement to replace Language Specific Characters in File.
We have set of characters, it should be replaced to a different character in the file.

I have around 38 characters which should replaced to different destination character.

Please help.

Thanks
Bharat

Hi,

What are your attempts?

Below one could be start point :

sed -e 's/C/C/;s/O/O/g' file

It gives desired output.

i added g for global replacement if same character has to be replaced more than once.

1 Like

Thanks a lot. I will test this and let you know.

Thanks
Bharat

How about

iconv -futf8 -tascii//translit file
Ex: "C" should be replaced as "C"
"O" should be replaced as "O"
1 Like