[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 2036
  • Last Modified:

AWK ( Print field before last)

I can print out the last field such as  awk '{ print $NF }'

how can i print out the last field and the Next to last field.......
0
bt707
Asked:
bt707
  • 2
1 Solution
 
bt707Author Commented:
looks like i got it,

awk '{print $NF, $(NF-1)}'
0
 
ahoffmannCommented:
congratulations for your own solution ;-)

I'll refund your 500 points.

{{ ahoffmann EE Page Editor }}
0
 
bt707Author Commented:
Thanks, I didn't know how to close this.
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now