<?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 printing in awk in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405248#M706355</link>
    <description>How do I print from a certain spot in a file to the end of the file??&lt;BR /&gt;&lt;BR /&gt;awk '/Start/?????/ {print $0}'</description>
    <pubDate>Thu, 21 Oct 2004 12:30:23 GMT</pubDate>
    <dc:creator>Jamie Collins</dc:creator>
    <dc:date>2004-10-21T12:30:23Z</dc:date>
    <item>
      <title>printing in awk</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405248#M706355</link>
      <description>How do I print from a certain spot in a file to the end of the file??&lt;BR /&gt;&lt;BR /&gt;awk '/Start/?????/ {print $0}'</description>
      <pubDate>Thu, 21 Oct 2004 12:30:23 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405248#M706355</guid>
      <dc:creator>Jamie Collins</dc:creator>
      <dc:date>2004-10-21T12:30:23Z</dc:date>
    </item>
    <item>
      <title>Re: printing in awk</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405249#M706356</link>
      <description>Hi Jamie,&lt;BR /&gt;&lt;BR /&gt;Try this awk one liner.&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://www.sap-basis-abap.com/unix/awk-one-liner-tips.htm" target="_blank"&gt;http://www.sap-basis-abap.com/unix/awk-one-liner-tips.htm&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;If it helps, print and keep a copy for future reference.&lt;BR /&gt;&lt;BR /&gt;Hope this helps.&lt;BR /&gt;&lt;BR /&gt;regds&lt;BR /&gt;</description>
      <pubDate>Thu, 21 Oct 2004 12:36:14 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405249#M706356</guid>
      <dc:creator>Sanjay_6</dc:creator>
      <dc:date>2004-10-21T12:36:14Z</dc:date>
    </item>
    <item>
      <title>Re: printing in awk</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405250#M706357</link>
      <description>The example I was looking for isn't in there.  I need to know what the end of file flag is in awk??  I thought it was $^ but that doesn't work.</description>
      <pubDate>Thu, 21 Oct 2004 12:45:52 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405250#M706357</guid>
      <dc:creator>Jamie Collins</dc:creator>
      <dc:date>2004-10-21T12:45:52Z</dc:date>
    </item>
    <item>
      <title>Re: printing in awk</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405251#M706358</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;Give us an example of what the line looks like at present and what you want it look like after awk. Are you trying to get a string after a column position or a match_case position.&lt;BR /&gt;&lt;BR /&gt;Hope this helps.&lt;BR /&gt;&lt;BR /&gt;Regds&lt;BR /&gt;</description>
      <pubDate>Thu, 21 Oct 2004 12:49:03 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405251#M706358</guid>
      <dc:creator>Sanjay_6</dc:creator>
      <dc:date>2004-10-21T12:49:03Z</dc:date>
    </item>
    <item>
      <title>Re: printing in awk</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405252#M706359</link>
      <description>0   Awaiting Message&lt;BR /&gt;    7856545 458458454 9987787&lt;BR /&gt;    0.0 0.0 0.0 0.0 &lt;BR /&gt;    0.1             0.2&lt;BR /&gt;    0.2&lt;BR /&gt;&lt;BR /&gt;79  RSSD Logical thread&lt;BR /&gt;    2154845 542154    2154325 &lt;BR /&gt;    0.0 0.1 0.0 0.10&lt;BR /&gt;    0.1             0.0&lt;BR /&gt;    0.10&lt;BR /&gt;&lt;BR /&gt;80  RSSD_thread RSSD&lt;BR /&gt;    4578512 2154215   2154687&lt;BR /&gt;    100.6 110.8 0.1 0.1&lt;BR /&gt;    1645.88         2489.01&lt;BR /&gt;    2489.10&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;The last two lines of the file are always going to be the lines I want so I guess if we could print out just the last two lines that would work also...</description>
      <pubDate>Thu, 21 Oct 2004 13:00:12 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405252#M706359</guid>
      <dc:creator>Jamie Collins</dc:creator>
      <dc:date>2004-10-21T13:00:12Z</dc:date>
    </item>
    <item>
      <title>Re: printing in awk</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405253#M706360</link>
      <description>Are we to assume that this is a single file and you want the last two lines. How about tail -2 file_name&lt;BR /&gt;&lt;BR /&gt;here &lt;BR /&gt;cat file_name&lt;BR /&gt;0 Awaiting Message&lt;BR /&gt;7856545 458458454 9987787&lt;BR /&gt;0.0 0.0 0.0 0.0 &lt;BR /&gt;0.1 0.2&lt;BR /&gt;0.2&lt;BR /&gt;&lt;BR /&gt;79 RSSD Logical thread&lt;BR /&gt;2154845 542154 2154325 &lt;BR /&gt;0.0 0.1 0.0 0.10&lt;BR /&gt;0.1 0.0&lt;BR /&gt;0.10&lt;BR /&gt;&lt;BR /&gt;80 RSSD_thread RSSD&lt;BR /&gt;4578512 2154215 2154687&lt;BR /&gt;100.6 110.8 0.1 0.1&lt;BR /&gt;1645.88 2489.01&lt;BR /&gt;2489.10&lt;BR /&gt;&lt;BR /&gt;And the results of "tail -2 file_name" would be&lt;BR /&gt;1645.88 2489.01&lt;BR /&gt;2489.10&lt;BR /&gt;&lt;BR /&gt;Is this what you want.&lt;BR /&gt;&lt;BR /&gt;Hope this helps.&lt;BR /&gt;&lt;BR /&gt;Regds&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Thu, 21 Oct 2004 13:09:32 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405253#M706360</guid>
      <dc:creator>Sanjay_6</dc:creator>
      <dc:date>2004-10-21T13:09:32Z</dc:date>
    </item>
    <item>
      <title>Re: printing in awk</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405254#M706361</link>
      <description>I was using tail but I already have an awk program and didn't want to deviate away from it...  I'll just use the tail and put it into a temp file...  Thanks</description>
      <pubDate>Thu, 21 Oct 2004 13:11:30 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405254#M706361</guid>
      <dc:creator>Jamie Collins</dc:creator>
      <dc:date>2004-10-21T13:11:30Z</dc:date>
    </item>
    <item>
      <title>Re: printing in awk</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405255#M706362</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;Just for reference, you can get awk to print from a specific line to the end of the file.  I got it to work like this, there may be a better way:&lt;BR /&gt;&lt;BR /&gt;awk '/Start/,/\*/ {print}'  somefile&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;JP&lt;BR /&gt;</description>
      <pubDate>Thu, 21 Oct 2004 13:15:48 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405255#M706362</guid>
      <dc:creator>John Poff</dc:creator>
      <dc:date>2004-10-21T13:15:48Z</dc:date>
    </item>
    <item>
      <title>Re: printing in awk</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405256#M706363</link>
      <description>Thanks..&lt;BR /&gt;I have another question though...&lt;BR /&gt;&lt;BR /&gt;I get output like this...&lt;BR /&gt;&lt;BR /&gt;1654.28&lt;BR /&gt;2498.07&lt;BR /&gt;&lt;BR /&gt;How do I subtract those two numbers?  They're on seperate lines.</description>
      <pubDate>Thu, 21 Oct 2004 13:18:26 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405256#M706363</guid>
      <dc:creator>Jamie Collins</dc:creator>
      <dc:date>2004-10-21T13:18:26Z</dc:date>
    </item>
    <item>
      <title>Re: printing in awk</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405257#M706364</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;Try this,&lt;BR /&gt;&lt;BR /&gt;awk '{y=x "\n" $0; x=$0};END{print y}' file_name&lt;BR /&gt;&lt;BR /&gt;Hope this helps.&lt;BR /&gt;&lt;BR /&gt;regds&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Thu, 21 Oct 2004 13:20:24 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405257#M706364</guid>
      <dc:creator>Sanjay_6</dc:creator>
      <dc:date>2004-10-21T13:20:24Z</dc:date>
    </item>
    <item>
      <title>Re: printing in awk</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405258#M706365</link>
      <description>hi,&lt;BR /&gt;&lt;BR /&gt;Try&lt;BR /&gt;&lt;BR /&gt;echo `cat file_name |awk '{y=x "\n" $0; x=$0};END{print y}'|awk '{for (i=1; i&amp;lt;=NF; i++) s=-$1-s}; END{print s}'`&lt;BR /&gt;&lt;BR /&gt;This will subract the last line from the last-1 line. They have to be numeric values.&lt;BR /&gt;&lt;BR /&gt;someone might have a shorter way.&lt;BR /&gt;&lt;BR /&gt;Hope this helps.&lt;BR /&gt;&lt;BR /&gt;Regds&lt;BR /&gt;</description>
      <pubDate>Thu, 21 Oct 2004 13:58:18 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405258#M706365</guid>
      <dc:creator>Sanjay_6</dc:creator>
      <dc:date>2004-10-21T13:58:18Z</dc:date>
    </item>
    <item>
      <title>Re: printing in awk</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405259#M706366</link>
      <description>Here is something pretty straight forward-&lt;BR /&gt; &lt;BR /&gt;awk '/Start/{a=1};{if (a) print $0}' file&lt;BR /&gt; &lt;BR /&gt;(how about assigning points to all that have helped...)&lt;BR /&gt; &lt;BR /&gt;HTH&lt;BR /&gt; &lt;BR /&gt;-- Rod Hills</description>
      <pubDate>Thu, 21 Oct 2004 15:29:58 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405259#M706366</guid>
      <dc:creator>Rodney Hills</dc:creator>
      <dc:date>2004-10-21T15:29:58Z</dc:date>
    </item>
    <item>
      <title>Re: printing in awk</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405260#M706367</link>
      <description>awk '{y=x; x=$1} END {print x-y}' inputfile&lt;BR /&gt;</description>
      <pubDate>Thu, 21 Oct 2004 21:13:29 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/printing-in-awk/m-p/3405260#M706367</guid>
      <dc:creator>Hein van den Heuvel</dc:creator>
      <dc:date>2004-10-21T21:13:29Z</dc:date>
    </item>
  </channel>
</rss>

