<?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 strptime drilldown token not working in Dashboards &amp; Visualizations</title>
    <link>https://community.splunk.com/t5/Dashboards-Visualizations/strptime-drilldown-token-not-working/m-p/415463#M27316</link>
    <description>&lt;P&gt;Hello, Im working on a dashboard for a client. I need to drilldown the earliest and latest time of my transaction's events. But still can't do it. The value has to go from a table to another.&lt;/P&gt;

&lt;P&gt;here is my table1:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;   &amp;lt;search&amp;gt;
          &amp;lt;query&amp;gt;mysearch  | transaction myfield | eval t2=_time + duration | eval start=strftime(_time, "%d/%m/%y %H:%M:%S:%3N"), finalization=strftime(t2, "%d/%m/%y %H:%M:%S:%3N")  | table finalization start duration myfields&amp;lt;/query&amp;gt;
        &amp;lt;/search&amp;gt;
          &amp;lt;drilldown&amp;gt;
          &amp;lt;eval token="earliest"&amp;gt;round(strptime($row.start$,"%d/%m/%y %H:%M:%S:%3N"),3)&amp;lt;/eval&amp;gt;
          &amp;lt;eval token="latest"&amp;gt;round(strptime($row.finalization$, "%d/%m/%y %H:%M:%S:%3N"),3)&amp;lt;/eval&amp;gt;
&amp;lt;/drilldown&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;and here is my table2:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;    &amp;lt;table depends="$muhtoken$"&amp;gt;
        &amp;lt;title&amp;gt;all events between $earliest$ and $latest$&amp;lt;/title&amp;gt;
        &amp;lt;search&amp;gt;
          &amp;lt;query&amp;gt;mysearch | mytable&amp;lt;/query&amp;gt;
    &amp;lt;earliest&amp;gt;$earliest$&amp;lt;/earliest&amp;gt;
          &amp;lt;latest&amp;gt;$latest$&amp;lt;/latest&amp;gt;        
&amp;lt;/search&amp;gt;

      &amp;lt;/table&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;the problem is both token values are 946695600  (1/1/2000), tried the round, but still. same value.&lt;/P&gt;

&lt;P&gt;thanks!&lt;BR /&gt;
P.s: version is 6.3.1&lt;/P&gt;</description>
    <pubDate>Fri, 26 Jul 2019 20:40:26 GMT</pubDate>
    <dc:creator>3DGjos</dc:creator>
    <dc:date>2019-07-26T20:40:26Z</dc:date>
    <item>
      <title>strptime drilldown token not working</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/strptime-drilldown-token-not-working/m-p/415463#M27316</link>
      <description>&lt;P&gt;Hello, Im working on a dashboard for a client. I need to drilldown the earliest and latest time of my transaction's events. But still can't do it. The value has to go from a table to another.&lt;/P&gt;

&lt;P&gt;here is my table1:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;   &amp;lt;search&amp;gt;
          &amp;lt;query&amp;gt;mysearch  | transaction myfield | eval t2=_time + duration | eval start=strftime(_time, "%d/%m/%y %H:%M:%S:%3N"), finalization=strftime(t2, "%d/%m/%y %H:%M:%S:%3N")  | table finalization start duration myfields&amp;lt;/query&amp;gt;
        &amp;lt;/search&amp;gt;
          &amp;lt;drilldown&amp;gt;
          &amp;lt;eval token="earliest"&amp;gt;round(strptime($row.start$,"%d/%m/%y %H:%M:%S:%3N"),3)&amp;lt;/eval&amp;gt;
          &amp;lt;eval token="latest"&amp;gt;round(strptime($row.finalization$, "%d/%m/%y %H:%M:%S:%3N"),3)&amp;lt;/eval&amp;gt;
&amp;lt;/drilldown&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;and here is my table2:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;    &amp;lt;table depends="$muhtoken$"&amp;gt;
        &amp;lt;title&amp;gt;all events between $earliest$ and $latest$&amp;lt;/title&amp;gt;
        &amp;lt;search&amp;gt;
          &amp;lt;query&amp;gt;mysearch | mytable&amp;lt;/query&amp;gt;
    &amp;lt;earliest&amp;gt;$earliest$&amp;lt;/earliest&amp;gt;
          &amp;lt;latest&amp;gt;$latest$&amp;lt;/latest&amp;gt;        
&amp;lt;/search&amp;gt;

      &amp;lt;/table&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;the problem is both token values are 946695600  (1/1/2000), tried the round, but still. same value.&lt;/P&gt;

&lt;P&gt;thanks!&lt;BR /&gt;
P.s: version is 6.3.1&lt;/P&gt;</description>
      <pubDate>Fri, 26 Jul 2019 20:40:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/strptime-drilldown-token-not-working/m-p/415463#M27316</guid>
      <dc:creator>3DGjos</dc:creator>
      <dc:date>2019-07-26T20:40:26Z</dc:date>
    </item>
    <item>
      <title>Re: strptime drilldown token not working</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/strptime-drilldown-token-not-working/m-p/415464#M27317</link>
      <description>&lt;P&gt;For me, the following works fine on 7.2 and I don't see why it wouldn't work on 6.3:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;panel&amp;gt;
  &amp;lt;title&amp;gt;final is $finalization$&amp;lt;/title&amp;gt;
  &amp;lt;table&amp;gt;
    &amp;lt;search&amp;gt;
      &amp;lt;query&amp;gt;| makeresults | eval start=strftime(relative_time(now(), "-50min"), "%d/%m/%y %H:%M:%S:%3N"), finalization=strftime(relative_time(now(), "-30min"), "%d/%m/%y %H:%M:%S:%3N")&amp;lt;/query&amp;gt;
      &amp;lt;earliest&amp;gt;-24h@h&amp;lt;/earliest&amp;gt;
      &amp;lt;latest&amp;gt;now&amp;lt;/latest&amp;gt;
    &amp;lt;/search&amp;gt;
    &amp;lt;option name="drilldown"&amp;gt;cell&amp;lt;/option&amp;gt;
    &amp;lt;drilldown&amp;gt;
      &amp;lt;eval token="start"&amp;gt;round(strptime($row.start$, "%d/%m/%y %H:%M:%S:%3N"), 3)&amp;lt;/eval&amp;gt;
      &amp;lt;eval token="finalization"&amp;gt;round(strptime($row.finalization$, "%d/%m/%y %H:%M:%S:%3N"), 3)&amp;lt;/eval&amp;gt;
    &amp;lt;/drilldown&amp;gt;
  &amp;lt;/table&amp;gt;
&amp;lt;/panel&amp;gt;
&amp;lt;panel&amp;gt;
  &amp;lt;table&amp;gt;
    &amp;lt;search&amp;gt;
      &amp;lt;query&amp;gt;| makeresults | eval start = "$start$", finalization = "$finalization$" | fieldformat start = strftime(start, "%d/%m/%y %H:%M:%S:%3N") | fieldformat finalization = strftime(finalization, "%d/%m/%y %H:%M:%S:%3N")&amp;lt;/query&amp;gt;
      &amp;lt;earliest&amp;gt;$start$&amp;lt;/earliest&amp;gt;
      &amp;lt;latest&amp;gt;$finalization$&amp;lt;/latest&amp;gt;
    &amp;lt;/search&amp;gt;
  &amp;lt;/table&amp;gt;
&amp;lt;/panel&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;What might cause issues is the fact you're using the global tokens, you might want to switch to custom names  as &lt;CODE&gt;$earliest$&lt;/CODE&gt; and &lt;CODE&gt;$latest$&lt;/CODE&gt; are always present on a dashboard. I've used &lt;CODE&gt;$drill_start$&lt;/CODE&gt; and &lt;CODE&gt;$drill_end$&lt;/CODE&gt; here.&lt;/P&gt;</description>
      <pubDate>Mon, 26 Aug 2019 17:21:51 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/strptime-drilldown-token-not-working/m-p/415464#M27317</guid>
      <dc:creator>jeffland</dc:creator>
      <dc:date>2019-08-26T17:21:51Z</dc:date>
    </item>
    <item>
      <title>Re: strptime drilldown token not working</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/strptime-drilldown-token-not-working/m-p/415465#M27318</link>
      <description>&lt;P&gt;One technique that may work for you is to include the native time values in your top query, but hide them from the user.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;search&amp;gt;
   &amp;lt;query&amp;gt;mysearch | transaction myfield | eval t2=_time + duration | eval start=strftime(_time, "%d/%m/%y %H:%M:%S:%3N"), finalization=strftime(t2, "%d/%m/%y %H:%M:%S:%3N") | rename start AS StartTime t2 AS EndTime | table finalization start duration myfields StartTime EndTime
   &amp;lt;/query&amp;gt;
&amp;lt;/search&amp;gt;
&amp;lt;option name=drilldown"&amp;gt;row&amp;lt;/option&amp;gt;
&amp;lt;fields&amp;gt;finalization start duration myfields&amp;lt;/fields&amp;gt;
&amp;lt;drilldown&amp;gt;
   &amp;lt;eval token="StartTime"&amp;gt;$row.StartTime$&amp;lt;/eval&amp;gt;
   &amp;lt;eval token="forms.StartTime"&amp;gt;$row.StartTime$&amp;lt;/eval&amp;gt;
   &amp;lt;eval token="EndTime"&amp;gt;$row.EndTime$&amp;lt;/eval&amp;gt;
   &amp;lt;eval token="forms.EndTime"&amp;gt;$row.EndTime$&amp;lt;/eval&amp;gt;
 &amp;lt;/drilldown&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Then you can use $StartTime$ and $EndTime$ in the receiving panel.&lt;/P&gt;

&lt;P&gt;I'd also suggest you comment out the fields line to have the times printed in the stats table, and confirm their accuracy. Avoid using reserved words like earliest and latest.&lt;/P&gt;</description>
      <pubDate>Mon, 26 Aug 2019 19:31:21 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/strptime-drilldown-token-not-working/m-p/415465#M27318</guid>
      <dc:creator>jpolvino</dc:creator>
      <dc:date>2019-08-26T19:31:21Z</dc:date>
    </item>
  </channel>
</rss>

