<?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: I want to specify a field which contains time as earliest and another field as latest so that my spl will be execute in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/I-want-to-specify-a-field-which-contains-time-as-earliest-and/m-p/594188#M206808</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/204073"&gt;@bapun18&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;if you want to use your fields, you can rename them but in the main search you have to use earliest and latest, not other field names, so if in your data you have&amp;nbsp;&lt;SPAN&gt;starttimeUTC and endtimeutc, you could use something like this:&lt;/SPAN&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;your_main_search [ search index=abcd | stats earliest(starttimeUTC) AS earliest latest(endtimeutc) AS latest ]
| ....&lt;/LI-CODE&gt;&lt;P&gt;Ciao.&lt;/P&gt;&lt;P&gt;Giuseppe&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 19 Apr 2022 06:38:03 GMT</pubDate>
    <dc:creator>gcusello</dc:creator>
    <dc:date>2022-04-19T06:38:03Z</dc:date>
    <item>
      <title>I want to specify a field which contains time as earliest and another field as latest so that my spl will be executed..</title>
      <link>https://community.splunk.com/t5/Splunk-Search/I-want-to-specify-a-field-which-contains-time-as-earliest-and/m-p/594177#M206804</link>
      <description>&lt;P&gt;I want to specify a field that contains time as earliest and another field as latest so that my spl will be executed with the earliest value of the earliest value of fileld1 and latest value as the latest value of the filed 2.&lt;BR /&gt;&lt;BR /&gt;Example,&lt;BR /&gt;index=abcd&amp;nbsp;&lt;BR /&gt;|table starttimeUTC endtimeutc&lt;BR /&gt;&lt;BR /&gt;in the above search should run as earliest=&amp;lt;earlier value of&amp;nbsp;tarttimeUTC&amp;gt; and latest=&amp;lt;latest value of&amp;nbsp;endtimeutc&amp;gt;&lt;/P&gt;</description>
      <pubDate>Tue, 19 Apr 2022 05:22:09 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/I-want-to-specify-a-field-which-contains-time-as-earliest-and/m-p/594177#M206804</guid>
      <dc:creator>bapun18</dc:creator>
      <dc:date>2022-04-19T05:22:09Z</dc:date>
    </item>
    <item>
      <title>Re: I want to specify a field which contains time as earliest and another field as latest so that my spl will be execute</title>
      <link>https://community.splunk.com/t5/Splunk-Search/I-want-to-specify-a-field-which-contains-time-as-earliest-and/m-p/594178#M206805</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/204073"&gt;@bapun18&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;you should try to use a simple search like this:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;your_main_search [ search index=abcd | stats earliest(_time) AS earliest latest(_time) AS latest ]
| ....&lt;/LI-CODE&gt;&lt;P&gt;it's important that you use the field names earliest and latest in the main search.&lt;/P&gt;&lt;P&gt;Ciao.&lt;/P&gt;&lt;P&gt;Giuseppe&lt;/P&gt;</description>
      <pubDate>Tue, 19 Apr 2022 05:53:14 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/I-want-to-specify-a-field-which-contains-time-as-earliest-and/m-p/594178#M206805</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2022-04-19T05:53:14Z</dc:date>
    </item>
    <item>
      <title>Re: I want to specify a field which contains time as earliest and another field as latest so that my spl will be execute</title>
      <link>https://community.splunk.com/t5/Splunk-Search/I-want-to-specify-a-field-which-contains-time-as-earliest-and/m-p/594188#M206808</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/204073"&gt;@bapun18&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;if you want to use your fields, you can rename them but in the main search you have to use earliest and latest, not other field names, so if in your data you have&amp;nbsp;&lt;SPAN&gt;starttimeUTC and endtimeutc, you could use something like this:&lt;/SPAN&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;your_main_search [ search index=abcd | stats earliest(starttimeUTC) AS earliest latest(endtimeutc) AS latest ]
| ....&lt;/LI-CODE&gt;&lt;P&gt;Ciao.&lt;/P&gt;&lt;P&gt;Giuseppe&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 19 Apr 2022 06:38:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/I-want-to-specify-a-field-which-contains-time-as-earliest-and/m-p/594188#M206808</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2022-04-19T06:38:03Z</dc:date>
    </item>
  </channel>
</rss>

