The above command is working fine. I am trying make it dynamic for swpping the field.I am struck where and how to start .My inputs should be the which column should come in first field and rest moving other side .Please find example for the above file
Swapfields.sh a.txt 5 8
5= First field in putputfile
8=number of fields.
@Guru. Thanks for the quick response. it is working as expected. I have used the same in my script .
---------- Post updated at 05:18 PM ---------- Previous update was at 05:12 PM ----------
@elixir,Pamu. Thanks for the reply. Your solution works perfect Need to learn more from You all and this forum makes me to learn and share my knowledge