To print the first field of a multiline record:
awk 'BEGIN {RS = ""} {print $1}'
If you want each line to be one field in the multiline record:
awk 'BEGIN { FS= "\n"; RS = "" } {print $1}'
9/07/2007
Using awk with multiline records
Posted: 11:53 AM
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment