Monthly Archives: March 2026

AWK/GAWK commands

Alter file with one column where data after newline corresponds to data in top section and create two comma separated columns from them:awk ‘NF==0{in2=1; next} !in2{a[++n]=$0; next} {print a[++i] “, ” $0}’ “infile.txt” > outfile.txt

Posted in Linux | Comments Off on AWK/GAWK commands