<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: grep using awk then head and tail in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792157#M943676</link>
    <description>Dang you guys are good, but I need to rephrase.&lt;BR /&gt;I need to go through a file, find all occurences of $name1, then echo out that line and the line prior to it.&lt;BR /&gt;I also need to find $name2 and echo out that line and several after it.&lt;BR /&gt;ie If I already know the line #, I can use "head -n line# | tail -1 or head +4.&lt;BR /&gt;Does that make more sense?&lt;BR /&gt;&lt;BR /&gt;Thanks again, ~jdk&lt;BR /&gt;ps ALL of you get and deserve 10 points eitherway&lt;BR /&gt;</description>
    <pubDate>Thu, 22 Aug 2002 19:33:09 GMT</pubDate>
    <dc:creator>TrustNo1</dc:creator>
    <dc:date>2002-08-22T19:33:09Z</dc:date>
    <item>
      <title>grep using awk then head and tail</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792152#M943671</link>
      <description>Im am try to retreive the line number of a grep return using awk and pass it to head -n then tail -2.&lt;BR /&gt;My feeble attempts need help!&lt;BR /&gt;I'mwas attempting to use;&lt;BR /&gt;cat -n $file | grep PARM | awk '{print $1}' | head -n ${1} $file .&lt;BR /&gt;the cat -n $file | grep PARM | awk '{print $1}' works fine, but how do I pass that to head -n ?&lt;BR /&gt;Thank you ~jdk</description>
      <pubDate>Thu, 22 Aug 2002 18:58:40 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792152#M943671</guid>
      <dc:creator>TrustNo1</dc:creator>
      <dc:date>2002-08-22T18:58:40Z</dc:date>
    </item>
    <item>
      <title>Re: grep using awk then head and tail</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792153#M943672</link>
      <description>To pass as a parameter, you would use the execute in place shell ability.&lt;BR /&gt;&lt;BR /&gt;example-&lt;BR /&gt;&lt;BR /&gt;head -n $(echo 4) filename&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;In your example, replace all those commands for the "echo 4".&lt;BR /&gt;&lt;BR /&gt;Their might be an easier way to do what you are trying to do. Can you rephrase your question in terms of what results you are looking for.&lt;BR /&gt;&lt;BR /&gt;-- Rod Hills</description>
      <pubDate>Thu, 22 Aug 2002 19:01:01 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792153#M943672</guid>
      <dc:creator>Rodney Hills</dc:creator>
      <dc:date>2002-08-22T19:01:01Z</dc:date>
    </item>
    <item>
      <title>Re: grep using awk then head and tail</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792154#M943673</link>
      <description>cat -n $file | grep PARM | awk '{print $1}' | xargs -i head -n {} $file&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;live free or die&lt;BR /&gt;harry</description>
      <pubDate>Thu, 22 Aug 2002 19:01:45 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792154#M943673</guid>
      <dc:creator>harry d brown jr</dc:creator>
      <dc:date>2002-08-22T19:01:45Z</dc:date>
    </item>
    <item>
      <title>Re: grep using awk then head and tail</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792155#M943674</link>
      <description>Hi&lt;BR /&gt;&lt;BR /&gt;Use&lt;BR /&gt;&lt;BR /&gt;cat $file | grep PARM | awk '{print $1}' | head -10&lt;BR /&gt;&lt;BR /&gt;HTH&lt;BR /&gt;&lt;BR /&gt;Steve&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Thu, 22 Aug 2002 19:04:49 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792155#M943674</guid>
      <dc:creator>steven Burgess_2</dc:creator>
      <dc:date>2002-08-22T19:04:49Z</dc:date>
    </item>
    <item>
      <title>Re: grep using awk then head and tail</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792156#M943675</link>
      <description>&lt;BR /&gt;Sample using an IOSCAN I did to a file:&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt; cat -n $file | grep C895 | awk '{print $1}' | xargs -i head -n {} $file&lt;BR /&gt;Class       I  H/W Path      Driver    S/W State   H/W Type     Description&lt;BR /&gt;============================================================================&lt;BR /&gt;root        0                root      CLAIMED     BUS_NEXUS    &lt;BR /&gt;ioa         0  0             sba       CLAIMED     BUS_NEXUS    System Bus Adapter (803)&lt;BR /&gt;ba          0  0/0           lba       CLAIMED     BUS_NEXUS    Local PCI Bus Adapter (782)&lt;BR /&gt;lan         0  0/0/0/0       btlan     CLAIMED     INTERFACE    HP PCI 10/100Base-TX Core&lt;BR /&gt;                            /dev/diag/lan0  /dev/ether0     /dev/lan0     &lt;BR /&gt;ext_bus     0  0/0/1/0       c720      CLAIMED     INTERFACE    SCSI C895 Fast Wide Single-Ended&lt;BR /&gt;# &lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;live free or die&lt;BR /&gt;harry</description>
      <pubDate>Thu, 22 Aug 2002 19:07:33 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792156#M943675</guid>
      <dc:creator>harry d brown jr</dc:creator>
      <dc:date>2002-08-22T19:07:33Z</dc:date>
    </item>
    <item>
      <title>Re: grep using awk then head and tail</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792157#M943676</link>
      <description>Dang you guys are good, but I need to rephrase.&lt;BR /&gt;I need to go through a file, find all occurences of $name1, then echo out that line and the line prior to it.&lt;BR /&gt;I also need to find $name2 and echo out that line and several after it.&lt;BR /&gt;ie If I already know the line #, I can use "head -n line# | tail -1 or head +4.&lt;BR /&gt;Does that make more sense?&lt;BR /&gt;&lt;BR /&gt;Thanks again, ~jdk&lt;BR /&gt;ps ALL of you get and deserve 10 points eitherway&lt;BR /&gt;</description>
      <pubDate>Thu, 22 Aug 2002 19:33:09 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792157#M943676</guid>
      <dc:creator>TrustNo1</dc:creator>
      <dc:date>2002-08-22T19:33:09Z</dc:date>
    </item>
    <item>
      <title>Re: grep using awk then head and tail</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792158#M943677</link>
      <description>Try playing with this, it'll blow your mind:&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;cat -n $file | grep C895 | awk '{printf "head -n %d %s \| tail -n %s\n",$1+2,"XZ&lt;BR /&gt;X",$1-1;}' | sed "s,XZX,${file},g" | xargs -i sh {}&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;live free or die&lt;BR /&gt;harry</description>
      <pubDate>Thu, 22 Aug 2002 19:34:21 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792158#M943677</guid>
      <dc:creator>harry d brown jr</dc:creator>
      <dc:date>2002-08-22T19:34:21Z</dc:date>
    </item>
    <item>
      <title>Re: grep using awk then head and tail</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792159#M943678</link>
      <description>Here is a way with perl-&lt;BR /&gt;&lt;BR /&gt;perl -n -e '$s2=$s1;$s1=$_;/mno/ &amp;amp;&amp;amp; do {print "$s2$s1"}' $file&lt;BR /&gt;&lt;BR /&gt;Hope this helps...&lt;BR /&gt;&lt;BR /&gt;-- Rod Hills</description>
      <pubDate>Thu, 22 Aug 2002 19:41:33 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792159#M943678</guid>
      <dc:creator>Rodney Hills</dc:creator>
      <dc:date>2002-08-22T19:41:33Z</dc:date>
    </item>
    <item>
      <title>Re: grep using awk then head and tail</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792160#M943679</link>
      <description>I originally thought this would work;&lt;BR /&gt;cat -n cmaudit | grep BEGIN | awk '{print $1}' | head -n '{print $1}' cmaudit | tail -5 . Can you point out the error of my ways?&lt;BR /&gt;&lt;BR /&gt;Harry, I'm using a test machine so I tried your mind blower, modified of course....it returned empty. I'm not quite sure I understand all it does, or if I could understand it anyway!&lt;BR /&gt;&lt;BR /&gt;I will give the perl scripting a try, and get back to you Rod.&lt;BR /&gt;&lt;BR /&gt;Thanks again! ~jdk</description>
      <pubDate>Thu, 22 Aug 2002 19:47:22 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792160#M943679</guid>
      <dc:creator>TrustNo1</dc:creator>
      <dc:date>2002-08-22T19:47:22Z</dc:date>
    </item>
    <item>
      <title>Re: grep using awk then head and tail</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792161#M943680</link>
      <description>Here is a more generic version-&lt;BR /&gt;&lt;BR /&gt;sed -n -e `grep -n $name1 $file | awk -F: '{print $1 - 1 "," $1 "p"}'` $file&lt;BR /&gt;sed -n -e `grep -n $name2 $file | awk -F: '{print $1 "," $1 + 7 "p"}'` $file&lt;BR /&gt;&lt;BR /&gt;The first finds $name1 and prints line prior and current line.&lt;BR /&gt;&lt;BR /&gt;The second finds $names and prints line plus 7 additional lines.&lt;BR /&gt;&lt;BR /&gt;Hope this helps.&lt;BR /&gt;&lt;BR /&gt;-- Rod Hills</description>
      <pubDate>Thu, 22 Aug 2002 19:56:35 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792161#M943680</guid>
      <dc:creator>Rodney Hills</dc:creator>
      <dc:date>2002-08-22T19:56:35Z</dc:date>
    </item>
    <item>
      <title>Re: grep using awk then head and tail</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792162#M943681</link>
      <description>A slight change to my previous "sed"&lt;BR /&gt;&lt;BR /&gt;sed -n -e "`grep -n \"mno\" infile | awk -F: '{print $1 - 1 \",\" $1 \"p\"}'`" infile&lt;BR /&gt;&lt;BR /&gt;I needed to put the result of the grep in double quotes following the -e option of sed.&lt;BR /&gt;&lt;BR /&gt;The \" are there so the shell will not treat them as matching the first ".&lt;BR /&gt;&lt;BR /&gt;This will now work for multiple finds of $name1.&lt;BR /&gt;&lt;BR /&gt;-- Rod Hills</description>
      <pubDate>Thu, 22 Aug 2002 20:08:44 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792162#M943681</guid>
      <dc:creator>Rodney Hills</dc:creator>
      <dc:date>2002-08-22T20:08:44Z</dc:date>
    </item>
    <item>
      <title>Re: grep using awk then head and tail</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792163#M943682</link>
      <description>Well, I never got exactly what I wanted from my buddy grep. A young lady next to me wrote (in a minute or so) a perl script that did the trick. It parses the file in short order....maybe I should have used "C".....&lt;BR /&gt;#!/usr/perl5/bin/perl5.00502&lt;BR /&gt;$srcfil = "cmaudit" ;&lt;BR /&gt;$srcdir = "/tmp/autosys/" ;&lt;BR /&gt;$outdir = "/tmp/autosys/" ;&lt;BR /&gt;$outfil = "sstimes.log" ;&lt;BR /&gt;##################################&lt;BR /&gt;# Open files&lt;BR /&gt;#&lt;BR /&gt;open ( INPFL, "${outdir}${srcfil}" ) ||&lt;BR /&gt;         die "Couldn't open ${outdir}${srcfil}" ;&lt;BR /&gt;open ( OUTFL, "&amp;gt;${outdir}${outfil}" ) ||&lt;BR /&gt;         die "Couldn't open ${outdir}${outfil}" ;&lt;BR /&gt;while ( &lt;INPFL&gt; )&lt;BR /&gt;{&lt;BR /&gt;#  chop ;&lt;BR /&gt;  $line = "$_" ;&lt;BR /&gt;  $begin = index($line, "BEGIN" ) ;&lt;BR /&gt;  if ( $begin != -1 ) {&lt;BR /&gt;    printf (OUTFL "%s", $line) ;&lt;BR /&gt;    $nline = &lt;INPFL&gt; ;&lt;BR /&gt;    printf (OUTFL "%s", $nline) ;&lt;BR /&gt;  } else {&lt;BR /&gt;      $finish = index($line, "FINISH" ) ;&lt;BR /&gt;      if ( $finish != -1 ) {&lt;BR /&gt;        printf (OUTFL "%s", $oline) ;&lt;BR /&gt;        printf (OUTFL "%s", $line) ;&lt;BR /&gt;      }&lt;BR /&gt;  }&lt;BR /&gt;  $oline = "$_" ;&lt;BR /&gt;} #End of while input&lt;BR /&gt;close (INPFL);&lt;BR /&gt;close (OUTFL);&lt;BR /&gt;exit;&lt;BR /&gt;&lt;BR /&gt;Thanks for all the GREAT ides though!&lt;BR /&gt;Some days you get the bear, blah, blah&lt;BR /&gt;~jdk&lt;/INPFL&gt;&lt;/INPFL&gt;</description>
      <pubDate>Fri, 23 Aug 2002 16:10:49 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792163#M943682</guid>
      <dc:creator>TrustNo1</dc:creator>
      <dc:date>2002-08-23T16:10:49Z</dc:date>
    </item>
    <item>
      <title>Re: grep using awk then head and tail</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792164#M943683</link>
      <description>cat -n cmaudit | grep BEGIN | awk '{printf "head -n %d %s \| tail -n %s\n",$1+2,"XZ&lt;BR /&gt;X",$1-1;}' | sed "s,XZX,${file},g" | xargs -i sh {}&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;live free or die&lt;BR /&gt;harry&lt;BR /&gt;cat -n cmaudit | grep BEGIN | awk '{print $1}' | head -n '{print $1}' cmaudit | tail -5 . Can you point out the error of my ways?&lt;BR /&gt;</description>
      <pubDate>Fri, 23 Aug 2002 16:45:57 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792164#M943683</guid>
      <dc:creator>harry d brown jr</dc:creator>
      <dc:date>2002-08-23T16:45:57Z</dc:date>
    </item>
    <item>
      <title>Re: grep using awk then head and tail</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792165#M943684</link>
      <description>sorry about that last post, PLEASE IGNORE.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;HOW ABOUT THIS:&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;cat -n cmaudit |&lt;BR /&gt;grep -e BEGIN -e FINISH |&lt;BR /&gt;awk 'BEGIN {pos_beg=0;pos_end=0;}&lt;BR /&gt;{if (pos_beg == 0) {pos_beg=$1;next;}&lt;BR /&gt; if (pos_end == 0) {pos_end=$1;next;}&lt;BR /&gt;} END {printf "head -n %d %s \| tail -n %s\n",pos_end,"cmaudit",pos_end-pos_beg+&lt;BR /&gt;1;}' |&lt;BR /&gt;xargs -i sh {}&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;live free or die&lt;BR /&gt;harry&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Fri, 23 Aug 2002 16:47:05 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792165#M943684</guid>
      <dc:creator>harry d brown jr</dc:creator>
      <dc:date>2002-08-23T16:47:05Z</dc:date>
    </item>
    <item>
      <title>Re: grep using awk then head and tail</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792166#M943685</link>
      <description>Harry, the last one extracts ALL of the first record BEGIN to FINISH. If you reeeeally want to, there is a sample datafile attached!&lt;BR /&gt;&lt;BR /&gt;~jdk</description>
      <pubDate>Fri, 23 Aug 2002 17:23:30 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792166#M943685</guid>
      <dc:creator>TrustNo1</dc:creator>
      <dc:date>2002-08-23T17:23:30Z</dc:date>
    </item>
    <item>
      <title>Re: grep using awk then head and tail</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792167#M943686</link>
      <description>So you want something like this:&lt;BR /&gt;&lt;BR /&gt;cat cmaudit |&lt;BR /&gt;awk 'BEGIN {startdisp=0;}&lt;BR /&gt;{if (match($0,/.*BEGIN.*/) &amp;gt; 0) {startdisp=1; }&lt;BR /&gt; if (startdisp == 1) {print $0;}&lt;BR /&gt; if (match($0,/.*FINISH.*/) &amp;gt; 0) {startdisp=0;}&lt;BR /&gt;}'&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Will print every BEGIN-to-FINISH section.&lt;BR /&gt;&lt;BR /&gt;live free or die&lt;BR /&gt;harry</description>
      <pubDate>Fri, 23 Aug 2002 18:55:42 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792167#M943686</guid>
      <dc:creator>harry d brown jr</dc:creator>
      <dc:date>2002-08-23T18:55:42Z</dc:date>
    </item>
    <item>
      <title>Re: grep using awk then head and tail</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792168#M943687</link>
      <description>Harry,&lt;BR /&gt;That also puts out too much.&lt;BR /&gt;Only need;&lt;BR /&gt;The BEGIN line and the line after it.&lt;BR /&gt;The FINISH line and the line before it.&lt;BR /&gt;&lt;BR /&gt;~jdk</description>
      <pubDate>Fri, 23 Aug 2002 19:09:47 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792168#M943687</guid>
      <dc:creator>TrustNo1</dc:creator>
      <dc:date>2002-08-23T19:09:47Z</dc:date>
    </item>
    <item>
      <title>Re: grep using awk then head and tail</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792169#M943688</link>
      <description>Like this:&lt;BR /&gt;&lt;BR /&gt;cat cmaudit | &lt;BR /&gt;awk 'BEGIN {startdisp=0;}&lt;BR /&gt;{&lt;BR /&gt; if (match($0,/.*BEGIN.*/) &amp;gt; 0) {print $0; startdisp=1; next;}&lt;BR /&gt; if (startdisp == 1) {print $0;startdisp=0;next;}&lt;BR /&gt; if (match($0,/.*FINISH.*/) &amp;gt; 0) {print prevline; print $0;startdisp=0;}&lt;BR /&gt; prevline=$0;&lt;BR /&gt;}' &lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;                ******BEGIN CIMCCV001******&lt;BR /&gt;Thu May 30 18:02:17 EDT 2002&lt;BR /&gt;Thu May 30 18:02:19 EDT 2002&lt;BR /&gt;******FINISH CIMCCV001******&lt;BR /&gt;******BEGIN CIMCCV002******&lt;BR /&gt;Thu May 30 23:52:31 EDT 2002&lt;BR /&gt;Thu May 30 23:52:31 EDT 2002&lt;BR /&gt;******FINISH CIMCCV002******&lt;BR /&gt;******BEGIN CSICSY001******&lt;BR /&gt;Thu May 30 18:56:16 EDT 2002&lt;BR /&gt;Thu May 30 18:56:54 EDT 2002&lt;BR /&gt;******FINISH CSICSY001******&lt;BR /&gt;******BEGIN CSICSY004******&lt;BR /&gt;Thu May 30 18:56:44 EDT 2002&lt;BR /&gt;&lt;BR /&gt;******FINISH CSICSY004******&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;though the last finish didn't have a time, except after it!&lt;BR /&gt;&lt;BR /&gt;live free or die&lt;BR /&gt;harry</description>
      <pubDate>Fri, 23 Aug 2002 19:24:18 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792169#M943688</guid>
      <dc:creator>harry d brown jr</dc:creator>
      <dc:date>2002-08-23T19:24:18Z</dc:date>
    </item>
    <item>
      <title>Re: grep using awk then head and tail</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792170#M943689</link>
      <description>BINGO!&lt;BR /&gt;&lt;BR /&gt;This runs as fast as the perl.&lt;BR /&gt;Unfortunatly, I'm not gifted enough to have figured out this on my own :( .&lt;BR /&gt;Well, thank you, I am going to keep this one for reference for a long time I hope!&lt;BR /&gt;&lt;BR /&gt;Have a GREAT weekend Harry,&lt;BR /&gt;~jdk</description>
      <pubDate>Fri, 23 Aug 2002 19:42:03 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792170#M943689</guid>
      <dc:creator>TrustNo1</dc:creator>
      <dc:date>2002-08-23T19:42:03Z</dc:date>
    </item>
    <item>
      <title>Re: grep using awk then head and tail</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792171#M943690</link>
      <description>If you wanted lines from BEGIN to FINISH, then the simple-&lt;BR /&gt;&lt;BR /&gt;sed -n -e '/BEGIN/,/FINISH/p' $file&lt;BR /&gt;&lt;BR /&gt;Is all you need...&lt;BR /&gt;&lt;BR /&gt;-- Rod Hills</description>
      <pubDate>Fri, 23 Aug 2002 20:24:40 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/grep-using-awk-then-head-and-tail/m-p/2792171#M943690</guid>
      <dc:creator>Rodney Hills</dc:creator>
      <dc:date>2002-08-23T20:24:40Z</dc:date>
    </item>
  </channel>
</rss>

