<?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: sorting in UX in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797170#M941176</link>
    <description>I'm not sure that I understand what you want.&lt;BR /&gt;&lt;BR /&gt;You input from message 1 and the output from message 2 are indentical....</description>
    <pubDate>Thu, 29 Aug 2002 23:32:43 GMT</pubDate>
    <dc:creator>Michael Tully</dc:creator>
    <dc:date>2002-08-29T23:32:43Z</dc:date>
    <item>
      <title>sorting in UX</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797168#M941174</link>
      <description>I have played around with sorting this but I can't seem to get it. I think it requires "cut" and "paste" but I have VERY little experience wtih them and I'm under the gun....I'm trying to sort by "Col#1" - "Year" - "Mo" - "Day" - "Time".&lt;BR /&gt;The input is;&lt;BR /&gt;CIMCCV001;Dec 30, 1999;13:25:51;Dec 30, 1999;13:25:51&lt;BR /&gt;CIMCCV002;Jan 12, 2000;06:47:21;Jan 12, 2000;06:47:21&lt;BR /&gt;CSICCD002;Dec 29, 1999;03:38:12;Dec 29, 1999;03:41:00&lt;BR /&gt;CSICCD002;Dec 31, 1999;04:00:44;Dec 30, 1999;04:32:44&lt;BR /&gt;CSICSY000;Jan 3, 2000;12:05:30;Jan 3, 2000;12:06:11&lt;BR /&gt;CSICSY001;Jan 4, 2000;12:05:45;Jan 4, 2000;12:06:22&lt;BR /&gt;CSICSY002;Jan 2, 2000;12:06:24;Jan 2, 2000;12:06:24&lt;BR /&gt;output should be;&lt;BR /&gt;CSICCD002;Dec 29, 1999;03:38:12;Dec 29, 1999;03:41:00&lt;BR /&gt;CIMCCV001;Dec 30, 1999;13:25:51;Dec 30, 1999;13:25:51&lt;BR /&gt;CSICCD002;Dec 31, 1999;04:00:44;Dec 30, 1999;04:32:44&lt;BR /&gt;CSICSY002;Jan 2, 2000;12:06:24;Jan 2, 2000;12:06:24&lt;BR /&gt;CSICSY000;Jan 3, 2000;12:05:30;Jan 3, 2000;12:06:11&lt;BR /&gt;CSICSY001;Jan 4, 2000;12:05:45;Jan 4, 2000;12:06:22&lt;BR /&gt;CIMCCV002;Jan 12, 2000;06:47:21;Jan 12, 2000;06:47:21&lt;BR /&gt;&lt;BR /&gt;Thanks ~jdk&lt;BR /&gt;</description>
      <pubDate>Thu, 29 Aug 2002 23:14:28 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797168#M941174</guid>
      <dc:creator>TrustNo1</dc:creator>
      <dc:date>2002-08-29T23:14:28Z</dc:date>
    </item>
    <item>
      <title>Re: sorting in UX</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797169#M941175</link>
      <description>Darn.....&lt;BR /&gt;Output should be;&lt;BR /&gt;CIMCCV001;Dec 30, 1999;13:25:51;Dec 30, 1999;13:25:51&lt;BR /&gt;CIMCCV002;Jan 12, 2000;06:47:21;Jan 12, 2000;06:47:21&lt;BR /&gt;CSICCD002;Dec 29, 1999;03:38:12;Dec 29, 1999;03:41:00&lt;BR /&gt;CSICCD002;Dec 31, 1999;04:00:44;Dec 30, 1999;04:32:44&lt;BR /&gt;CSICSY000;Jan 3, 2000;12:05:30;Jan 3, 2000;12:06:11&lt;BR /&gt;CSICSY001;Jan 4, 2000;12:05:45;Jan 4, 2000;12:06:22&lt;BR /&gt;CSICSY002;Jan 2, 2000;12:06:24;Jan 2, 2000;12:06:24&lt;BR /&gt;~jdk</description>
      <pubDate>Thu, 29 Aug 2002 23:18:26 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797169#M941175</guid>
      <dc:creator>TrustNo1</dc:creator>
      <dc:date>2002-08-29T23:18:26Z</dc:date>
    </item>
    <item>
      <title>Re: sorting in UX</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797170#M941176</link>
      <description>I'm not sure that I understand what you want.&lt;BR /&gt;&lt;BR /&gt;You input from message 1 and the output from message 2 are indentical....</description>
      <pubDate>Thu, 29 Aug 2002 23:32:43 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797170#M941176</guid>
      <dc:creator>Michael Tully</dc:creator>
      <dc:date>2002-08-29T23:32:43Z</dc:date>
    </item>
    <item>
      <title>Re: sorting in UX</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797171#M941177</link>
      <description>Geeze I must be getting tired, sorry...&lt;BR /&gt;The first line should end up being the fifth line on output.&lt;BR /&gt;input;&lt;BR /&gt;CSICCD002;Jan 3, 2000;12:05:30;Jan 3, 2000;12:06:11&lt;BR /&gt;CIMCCV001;Dec 30, 1999;13:25:51;Dec 30, 1999;13:25:51&lt;BR /&gt;CIMCCV002;Jan 12, 2000;06:47:21;Jan 12, 2000;06:47:21&lt;BR /&gt;CSICCD002;Dec 29, 1999;03:38:12;Dec 29, 1999;03:41:00&lt;BR /&gt;CSICCD002;Dec 31, 1999;04:00:44;Dec 30, 1999;04:32:44&lt;BR /&gt;CSICSY000;Jan 3, 2000;12:05:30;Jan 3, 2000;12:06:11&lt;BR /&gt;CSICSY001;Jan 4, 2000;12:05:45;Jan 4, 2000;12:06:22&lt;BR /&gt;CSICSY002;Jan 2, 2000;12:06:24;Jan 2, 2000;12:06:24&lt;BR /&gt;&lt;BR /&gt;output;&lt;BR /&gt;CIMCCV001;Dec 30, 1999;13:25:51;Dec 30, 1999;13:25:51&lt;BR /&gt;CIMCCV002;Jan 12, 2000;06:47:21;Jan 12, 2000;06:47:21&lt;BR /&gt;CSICCD002;Dec 29, 1999;03:38:12;Dec 29, 1999;03:41:00&lt;BR /&gt;CSICCD002;Dec 31, 1999;04:00:44;Dec 30, 1999;04:32:44&lt;BR /&gt;CSICCD002;Jan 3, 2000;12:05:30;Jan 3, 2000;12:06:11&lt;BR /&gt;CSICSY000;Jan 3, 2000;12:05:30;Jan 3, 2000;12:06:11&lt;BR /&gt;CSICSY001;Jan 4, 2000;12:05:45;Jan 4, 2000;12:06:22&lt;BR /&gt;CSICSY002;Jan 2, 2000;12:06:24;Jan 2, 2000;12:06:24&lt;BR /&gt;~jdk</description>
      <pubDate>Thu, 29 Aug 2002 23:46:32 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797171#M941177</guid>
      <dc:creator>TrustNo1</dc:creator>
      <dc:date>2002-08-29T23:46:32Z</dc:date>
    </item>
    <item>
      <title>Re: sorting in UX</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797172#M941178</link>
      <description>okay... let's try this. Assume your input is in file1 and you want line 1 from that file to end up in file2 on line 5. Because basically we are doing an alphabetical sort and remove duplicate lines....&lt;BR /&gt;&lt;BR /&gt;cat file1 | sort -u &amp;gt;file2&lt;BR /&gt;&lt;BR /&gt;HTH&lt;BR /&gt;Michael</description>
      <pubDate>Thu, 29 Aug 2002 23:55:13 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797172#M941178</guid>
      <dc:creator>Michael Tully</dc:creator>
      <dc:date>2002-08-29T23:55:13Z</dc:date>
    </item>
    <item>
      <title>Re: sorting in UX</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797173#M941179</link>
      <description>Hi:&lt;BR /&gt;&lt;BR /&gt;Try this:&lt;BR /&gt;&lt;BR /&gt;# sort -t\; -k1,9 -kb2.9,2.12 -kM2,3 -kb2.5,2.6 -k3 filein &amp;gt; fileout&lt;BR /&gt;&lt;BR /&gt;Regards!&lt;BR /&gt;&lt;BR /&gt;...JRF...&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Fri, 30 Aug 2002 00:11:11 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797173#M941179</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2002-08-30T00:11:11Z</dc:date>
    </item>
    <item>
      <title>Re: sorting in UX</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797174#M941180</link>
      <description>James &amp;amp; Michael, they both output the same, although James's is a bit more interesting!&lt;BR /&gt;outputs;&lt;BR /&gt;CSICSY001       9-Nov-2000      18:00:46        9-Nov-2000      18:01:25&lt;BR /&gt;CSICSY001       9-Oct-1999      12:46:12        9-Oct-1999      12:46:46&lt;BR /&gt;CSICSY001       9-Oct-2000      18:00:46        9-Oct-2000      18:01:19&lt;BR /&gt;CSICSY001       9-Sep-1999      18:24:06        9-Sep-1999      18:24:41&lt;BR /&gt;CSICSY001       9-Sep-2000      12:47:10        9-Sep-2000      12:47:43&lt;BR /&gt;CSICSY002       1-Apr-2000      12:00:34        1-Apr-2000      12:00:34&lt;BR /&gt;CSICSY002       1-Aug-2000      18:02:46        1-Aug-2000      18:02:46&lt;BR /&gt;&lt;BR /&gt;But I need to gather them by year, as well as the first column&lt;BR /&gt;&lt;BR /&gt;CSICSY001       9-Sep-1999      18:24:06        9-Sep-1999      18:24:41&lt;BR /&gt;CSICSY001       9-Oct-1999      12:46:12        9-Oct-1999      12:46:46&lt;BR /&gt;CSICSY001       9-Sep-2000      12:47:10        9-Sep-2000      12:47:43&lt;BR /&gt;CSICSY001       9-Oct-2000      18:00:46        9-Oct-2000      18:01:19&lt;BR /&gt;CSICSY001       9-Nov-2000      18:00:46        9-Nov-2000      18:01:25&lt;BR /&gt;CSICSY002       1-Apr-2000      12:00:34        1-Apr-2000      12:00:34&lt;BR /&gt;CSICSY002       1-Aug-2000      18:02:46        1-Aug-2000      18:02:46&lt;BR /&gt;&lt;BR /&gt;Thanks again!  ~jdk</description>
      <pubDate>Fri, 30 Aug 2002 00:55:44 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797174#M941180</guid>
      <dc:creator>TrustNo1</dc:creator>
      <dc:date>2002-08-30T00:55:44Z</dc:date>
    </item>
    <item>
      <title>Re: sorting in UX</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797175#M941181</link>
      <description>Hi:&lt;BR /&gt;&lt;BR /&gt;You've presented a differnt input format, so applying the 'sort' I suggested in my first post will *not* do as you first asked.&lt;BR /&gt;&lt;BR /&gt;I suggest you look at the man page for 'sort'.&lt;BR /&gt;&lt;BR /&gt;Regards!&lt;BR /&gt;&lt;BR /&gt;...JRF...</description>
      <pubDate>Fri, 30 Aug 2002 01:11:18 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797175#M941181</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2002-08-30T01:11:18Z</dc:date>
    </item>
    <item>
      <title>Re: sorting in UX</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797176#M941182</link>
      <description>Dang it, I picked up output from an excel experiment James.&lt;BR /&gt;Can we try this one more time?&lt;BR /&gt;input:&lt;BR /&gt;CSICSY001 Nov 9, 2000 18:00:46 9-Nov-2000 18:01:25&lt;BR /&gt;CSICSY001 Oct 9, 1999 12:46:12 9-Oct-1999 12:46:46&lt;BR /&gt;CSICSY001 Oct 9, 2000 18:00:46 9-Oct-2000 18:01:19&lt;BR /&gt;CSICSY001 Sep 19, 1999 18:24:06 9-Sep-1999 18:24:41&lt;BR /&gt;CSICSY001 Sep 9, 2000 12:47:10 9-Sep-2000 12:47:43&lt;BR /&gt;output;&lt;BR /&gt;CSICSY001 Sep 19, 1999 18:24:06 9-Sep-1999 18:24:41&lt;BR /&gt;CSICSY001 Oct 9, 1999 12:46:12 9-Oct-1999 12:46:46&lt;BR /&gt;CSICSY001 Sep 9, 2000 12:47:10 9-Sep-2000 12:47:43&lt;BR /&gt;CSICSY001 Oct 9, 2000 18:00:46 9-Oct-2000 18:01:19&lt;BR /&gt;CSICSY001 Nov 9, 2000 18:00:46 9-Nov-2000 18:01:25&lt;BR /&gt;~jdk</description>
      <pubDate>Fri, 30 Aug 2002 01:36:30 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797176#M941182</guid>
      <dc:creator>TrustNo1</dc:creator>
      <dc:date>2002-08-30T01:36:30Z</dc:date>
    </item>
    <item>
      <title>Re: sorting in UX</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797177#M941183</link>
      <description>James, never mind, I messed up again, forgot the delimeters + messed up the "right" side dates.&lt;BR /&gt;&lt;BR /&gt;I'll look at sort again in the morning.......sorry for the waste of time  :(    ~jdk</description>
      <pubDate>Fri, 30 Aug 2002 01:41:25 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797177#M941183</guid>
      <dc:creator>TrustNo1</dc:creator>
      <dc:date>2002-08-30T01:41:25Z</dc:date>
    </item>
    <item>
      <title>Re: sorting in UX</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797178#M941184</link>
      <description>You need to convert the date into something sortable.&lt;BR /&gt;&lt;BR /&gt;Create a file called sortdate.pl to hold a smal perl script-&lt;BR /&gt;BEGIN{@d{qw/Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec/}=(1,2,3,4,5,6,7,8,9&lt;BR /&gt;,10,11,12);}&lt;BR /&gt;{chop;split;($dd,$mth,$yy)=split("-",$_[5]);&lt;BR /&gt;printf "%4d%2.2d%2.2d%8s %s\n",$yy,$d{$mth},$dd,$_[6],$_;&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;Then you can do the following-&lt;BR /&gt;&lt;BR /&gt;cat inputfile | perl -n sortdate.pl | sort -kn1,1 | cut -f 2- &amp;gt;outputfile&lt;BR /&gt;&lt;BR /&gt;Hope this helps...&lt;BR /&gt;&lt;BR /&gt;-- Rod Hills</description>
      <pubDate>Fri, 30 Aug 2002 02:27:47 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797178#M941184</guid>
      <dc:creator>Rodney Hills</dc:creator>
      <dc:date>2002-08-30T02:27:47Z</dc:date>
    </item>
    <item>
      <title>Re: sorting in UX</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797179#M941185</link>
      <description>This morning it makes sense.&lt;BR /&gt;While asking you guys the "sort" question, a "helper" was importing and exporting the file to/from Excell and saving the results in the UX system under the original name.&lt;BR /&gt;The Excell activity had changed the date format!&lt;BR /&gt;Man, I knew I was tired last night, but I thought I was loosing it!.&lt;BR /&gt;A restore, and the use of your scripts did the trick!&lt;BR /&gt;&lt;BR /&gt;Thanks again for all the help,&lt;BR /&gt;I promise to do some serious looking at the "sort" man page.&lt;BR /&gt;&lt;BR /&gt;Have a GREAT weekend!&lt;BR /&gt;~jdk</description>
      <pubDate>Fri, 30 Aug 2002 13:54:27 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sorting-in-ux/m-p/2797179#M941185</guid>
      <dc:creator>TrustNo1</dc:creator>
      <dc:date>2002-08-30T13:54:27Z</dc:date>
    </item>
  </channel>
</rss>

