Created
August 21, 2012 22:22
-
-
Save eegrok/3419977 to your computer and use it in GitHub Desktop.
awk retrieve specific row / column
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2nd row 4th column | |
cat blah | awk 'NR==2 {printf "%s", $4}' | |
NR -- ordinal number of the current record | |
NF -- number of fields in the current record | |
(see man for awk for other stuff) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment