<?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: How to sort time so that minute values are in correct order relevant to a 60 minute hour? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-sort-time-so-that-minute-values-are-in-correct-order/m-p/215490#M63173</link>
    <description>&lt;PRE&gt;&lt;CODE&gt;|eval Time=strftime(_time, "%H:%M:%S") | eval Date=strftime(_time, "%A %F") 
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;This works too&lt;/P&gt;

&lt;P&gt;Thanks!&lt;/P&gt;</description>
    <pubDate>Mon, 15 Aug 2016 15:26:17 GMT</pubDate>
    <dc:creator>packet_hunter</dc:creator>
    <dc:date>2016-08-15T15:26:17Z</dc:date>
    <item>
      <title>How to sort time so that minute values are in correct order relevant to a 60 minute hour?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-sort-time-so-that-minute-values-are-in-correct-order/m-p/215484#M63167</link>
      <description>&lt;P&gt;Here is the data when sorted recent first....&lt;/P&gt;

&lt;P&gt;11:25:22&lt;BR /&gt;
11:25:23&lt;BR /&gt;
11:25:51&lt;BR /&gt;
11:25:52&lt;BR /&gt;
11:25:53&lt;BR /&gt;
11:5:37&lt;BR /&gt;
11:5:38&lt;BR /&gt;
11:5:42&lt;BR /&gt;
11:6:2&lt;BR /&gt;
11:6:5&lt;BR /&gt;
11:6:6 &lt;/P&gt;

&lt;P&gt;Any ideas?&lt;/P&gt;</description>
      <pubDate>Mon, 08 Aug 2016 19:43:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-sort-time-so-that-minute-values-are-in-correct-order/m-p/215484#M63167</guid>
      <dc:creator>packet_hunter</dc:creator>
      <dc:date>2016-08-08T19:43:50Z</dc:date>
    </item>
    <item>
      <title>Re: How to sort time so that minute values are in correct order relevant to a 60 minute hour?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-sort-time-so-that-minute-values-are-in-correct-order/m-p/215485#M63168</link>
      <description>&lt;PRE&gt;&lt;CODE&gt;....|eval Time=date_hour.":".date_minute.":".date_second  | eval Date = date_wday."  ".date_month."/".date_mday."/".date_year 
|stats list(message_subject) as subj list(sender) as sender list(recipient) as recp list(file_name) as AttachmentName list(attachment_type) as AttachmentType list(vendor_action) as status values(Time) as Time values(Date) as Date by internal_message_id ....
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;This is a sample of the code I use to get the events with time and date...&lt;/P&gt;</description>
      <pubDate>Mon, 08 Aug 2016 19:47:02 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-sort-time-so-that-minute-values-are-in-correct-order/m-p/215485#M63168</guid>
      <dc:creator>packet_hunter</dc:creator>
      <dc:date>2016-08-08T19:47:02Z</dc:date>
    </item>
    <item>
      <title>Re: How to sort time so that minute values are in correct order relevant to a 60 minute hour?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-sort-time-so-that-minute-values-are-in-correct-order/m-p/215486#M63169</link>
      <description>&lt;P&gt;Try this&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;.... | eval Time=strftime(strptime(date_hour.":".date_minute.":".date_second,"%H:%M:%S"),"%H:%M:%S) | ...
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;It should normalize Time to use 2-digit minute and second fields (hour, too).  Then the events will sort properly.&lt;/P&gt;</description>
      <pubDate>Mon, 08 Aug 2016 20:46:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-sort-time-so-that-minute-values-are-in-correct-order/m-p/215486#M63169</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2016-08-08T20:46:57Z</dc:date>
    </item>
    <item>
      <title>Re: How to sort time so that minute values are in correct order relevant to a 60 minute hour?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-sort-time-so-that-minute-values-are-in-correct-order/m-p/215487#M63170</link>
      <description>&lt;P&gt;Thank you Rick!!!   Do you also have the date cure too?   So that days and months are in the proper chronological order.   &lt;/P&gt;

&lt;P&gt;Thanks again&lt;/P&gt;</description>
      <pubDate>Mon, 08 Aug 2016 20:52:05 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-sort-time-so-that-minute-values-are-in-correct-order/m-p/215487#M63170</guid>
      <dc:creator>packet_hunter</dc:creator>
      <dc:date>2016-08-08T20:52:05Z</dc:date>
    </item>
    <item>
      <title>Re: How to sort time so that minute values are in correct order relevant to a 60 minute hour?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-sort-time-so-that-minute-values-are-in-correct-order/m-p/215488#M63171</link>
      <description>&lt;P&gt;Date is similar.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;... | eval Date=strftime(strptime(date_wday."  ".date_month."/".date_mday."/".date_year, "%a %m/%d/%Y"),"%a %m/%d/%Y") | ...
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I suspect, however, there's a better way using _time to get the events in order.  Depends on what you're trying to do.&lt;/P&gt;</description>
      <pubDate>Mon, 08 Aug 2016 21:06:58 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-sort-time-so-that-minute-values-are-in-correct-order/m-p/215488#M63171</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2016-08-08T21:06:58Z</dc:date>
    </item>
    <item>
      <title>Re: How to sort time so that minute values are in correct order relevant to a 60 minute hour?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-sort-time-so-that-minute-values-are-in-correct-order/m-p/215489#M63172</link>
      <description>&lt;P&gt;agreed, I am sure there is a better way but this should get the answers I need today...&lt;BR /&gt;
Thank you&lt;/P&gt;</description>
      <pubDate>Mon, 08 Aug 2016 21:39:27 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-sort-time-so-that-minute-values-are-in-correct-order/m-p/215489#M63172</guid>
      <dc:creator>packet_hunter</dc:creator>
      <dc:date>2016-08-08T21:39:27Z</dc:date>
    </item>
    <item>
      <title>Re: How to sort time so that minute values are in correct order relevant to a 60 minute hour?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-sort-time-so-that-minute-values-are-in-correct-order/m-p/215490#M63173</link>
      <description>&lt;PRE&gt;&lt;CODE&gt;|eval Time=strftime(_time, "%H:%M:%S") | eval Date=strftime(_time, "%A %F") 
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;This works too&lt;/P&gt;

&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Mon, 15 Aug 2016 15:26:17 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-sort-time-so-that-minute-values-are-in-correct-order/m-p/215490#M63173</guid>
      <dc:creator>packet_hunter</dc:creator>
      <dc:date>2016-08-15T15:26:17Z</dc:date>
    </item>
  </channel>
</rss>

