From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <102653649621804.tru64-unix-managers.marc@archive.invalid> From: bac Date: Tue, 12 Jun 2001 21:40:10 +0000 To: tru64-unix-managers Subject: SUMMARY: grep question X-MARC-Message: https://marc.info/?l=tru64-unix-managers&m=102653649621804 The question was: In a file that contains multiple instances of the following type of text, I only want to extract the numbers.... (2 lines after 'CPU Summary') # CPU SUMMARY # USER SYS IDLE WAIT INTR SYSC CS RUNQ AVG5 AVG30 AVG60 FORK VFORK 1 2 97 0 25 6855 631 0 0.11 0.23 0.22 0.60 For example I only want: 1 2 97 0 25 6855 631 0 0.11 0.23 0.22 0.60 How can I do this? Thanks Thanks to: alan@ nabeth.cxo.dec.com Mark Scarborough Markley, Sean Thomas M. Payerle Jim Fitzmaurice system PRIVILEGED account Jerome M Berkman Rob McCauley Michael Bucholtz Dr. Thomas.Blinn@ Compaq.com Eubank, Chris Benton, Marco Paul LaMadeleine The responses were overwhelming--Apparently there are many ways to do this including awk scripts and grep statements and others. Dr. Blinn suggested using grep -v '[A-Za-z]' file which removes all the characters from the file that is grep'd....This worked for me Thanks again __________________________________________________ Do You Yahoo!? Get personalized email addresses from Yahoo! Mail - only $35 a year! http://personal.mail.yahoo.com/