Reputation: 203
I would like do the following using awk:
The file use tab as field separator
Example of my input with the header and the first row of data
"Column1" "Column2" "Column3" "Column4" "Column5"
"a1" "b2" "c3" "d4" "e5"
Desired output
"Column4" "Column1" "Column2" "Column3" "Column5"
"d4" "a1" "b2" "c3" "e5"
Upvotes: 1
Views: 120
Reputation: 17258
Just need to arrange the fields in the desired order:
awk '{print $4, $1, $2, $3, $5}' your-file
Upvotes: 1