<?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: unix scripting in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/unix-scripting/m-p/2550529#M28031</link>
    <description>Hi:&lt;BR /&gt;&lt;BR /&gt;Oops, forgot to show the input/output to the sort:&lt;BR /&gt;&lt;BR /&gt;# sort -k 2nb /tmp/input &amp;gt; /tmp/output&lt;BR /&gt;&lt;BR /&gt;...JRF...</description>
    <pubDate>Tue, 10 Jul 2001 00:59:00 GMT</pubDate>
    <dc:creator>James R. Ferguson</dc:creator>
    <dc:date>2001-07-10T00:59:00Z</dc:date>
    <item>
      <title>unix scripting</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/unix-scripting/m-p/2550526#M28028</link>
      <description>I left my scripting book at work  and need a quick script to read in my text file and put the numbers in order which aren't necessarily at the beginning of the line.  For instance, the text file looks like this:&lt;BR /&gt;&lt;BR /&gt;Me9999ne&lt;BR /&gt;dog189&lt;BR /&gt;Horse8454&lt;BR /&gt;&lt;BR /&gt;I want the new file to look like this:&lt;BR /&gt;Dog189&lt;BR /&gt;Horse8454&lt;BR /&gt;Me9999&lt;BR /&gt;&lt;BR /&gt;Can someone please help me out here?&lt;BR /&gt;&lt;BR /&gt;Thanks</description>
      <pubDate>Mon, 09 Jul 2001 23:45:58 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/unix-scripting/m-p/2550526#M28028</guid>
      <dc:creator>Kerilyn O'Donnell</dc:creator>
      <dc:date>2001-07-09T23:45:58Z</dc:date>
    </item>
    <item>
      <title>Re: unix scripting</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/unix-scripting/m-p/2550527#M28029</link>
      <description>Hi:&lt;BR /&gt;&lt;BR /&gt;If the numeric portion of the record (line) is separated from the alphabetic string, then treat it as the sort key and sort.  For instance if the field separator is a blank and the numbers are the second field you could code:&lt;BR /&gt;&lt;BR /&gt;# sort -k 2nb&lt;BR /&gt;&lt;BR /&gt;Take a look at the man pages for 'sort' for more details.&lt;BR /&gt;&lt;BR /&gt;...JRF...</description>
      <pubDate>Tue, 10 Jul 2001 00:51:25 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/unix-scripting/m-p/2550527#M28029</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2001-07-10T00:51:25Z</dc:date>
    </item>
    <item>
      <title>Re: unix scripting</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/unix-scripting/m-p/2550528#M28030</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;Use sort command  to do this task...&lt;BR /&gt;&lt;BR /&gt;cat filename | sort &lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;&lt;BR /&gt;Paulson</description>
      <pubDate>Tue, 10 Jul 2001 00:52:15 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/unix-scripting/m-p/2550528#M28030</guid>
      <dc:creator>vtpaulson</dc:creator>
      <dc:date>2001-07-10T00:52:15Z</dc:date>
    </item>
    <item>
      <title>Re: unix scripting</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/unix-scripting/m-p/2550529#M28031</link>
      <description>Hi:&lt;BR /&gt;&lt;BR /&gt;Oops, forgot to show the input/output to the sort:&lt;BR /&gt;&lt;BR /&gt;# sort -k 2nb /tmp/input &amp;gt; /tmp/output&lt;BR /&gt;&lt;BR /&gt;...JRF...</description>
      <pubDate>Tue, 10 Jul 2001 00:59:00 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/unix-scripting/m-p/2550529#M28031</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2001-07-10T00:59:00Z</dc:date>
    </item>
    <item>
      <title>Re: unix scripting</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/unix-scripting/m-p/2550530#M28032</link>
      <description>sed 's/[0-9]/ &amp;amp;/' {file} | sort -k 2nb | sed 's/ //'&lt;BR /&gt;&lt;BR /&gt;will give you the blank before the 1st number, sort it, then remove the blank.&lt;BR /&gt;&lt;BR /&gt;Robin.</description>
      <pubDate>Tue, 10 Jul 2001 06:18:44 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/unix-scripting/m-p/2550530#M28032</guid>
      <dc:creator>Robin Wakefield</dc:creator>
      <dc:date>2001-07-10T06:18:44Z</dc:date>
    </item>
  </channel>
</rss>

