I have the following line:
pr: 10.00 20.00
I want to replace the third column with "00.00" while preserving tabs and spaces on the line.There's a space between the first and second column, and a tab between second and third column. The following command works EXCEPT it inserts a tab between the first and second column:
awk '$1=="pr:"{OFS="\t"; $3="00.00"}1' mydata.txt > out
How can I keep the space and tabs as they appear in the original line?
Thanks!