I have semicolon-separated columns, and I would like to add some characters to a specific column.
aaa;111;bbb
ccc;222;ddd
eee;333;fff
to the second column I want to add '@', so the output should be;
aaa;@111;bbb
ccc;@222;ddd
eee;@333;fff
I tried
awk -F';' -OFS=';' '{ $2 = "@" $2}1' file
It adds the character but removes all semicolons with space.