ubuntu:file:swap_fields_in_a_file
This is an old revision of the document!
Ubuntu - File - Swap fields in a file
Swap the first 2 fields.
awk '{tmp = $1; $1 = $2; $2 = tmp; print}' filename
ubuntu/file/swap_fields_in_a_file.1574890251.txt.gz · Last modified: 2020/07/15 09:30 (external edit)