<?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 how to create the below mentioned table? in Dashboards &amp; Visualizations</title>
    <link>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433881#M41500</link>
    <description>&lt;P&gt;how to create the below mentioned table? I want Duration in minute and duration in seconds.&lt;/P&gt;

&lt;P&gt;Job_Name       StartTime                           EndTime                      Duration_Min    Duration_Sec&lt;BR /&gt;
 gc01iwcft      2018/05/31 22:45:00            2018/05/31 22:45:02&lt;BR /&gt;
                        2018/05/31 23:00:01            2018/05/31 23:00:03&lt;BR /&gt;
                        2018/05/31 23:15:00            2018/05/31 23:15:01&lt;/P&gt;</description>
    <pubDate>Tue, 29 Sep 2020 19:48:14 GMT</pubDate>
    <dc:creator>abhi04</dc:creator>
    <dc:date>2020-09-29T19:48:14Z</dc:date>
    <item>
      <title>how to create the below mentioned table?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433881#M41500</link>
      <description>&lt;P&gt;how to create the below mentioned table? I want Duration in minute and duration in seconds.&lt;/P&gt;

&lt;P&gt;Job_Name       StartTime                           EndTime                      Duration_Min    Duration_Sec&lt;BR /&gt;
 gc01iwcft      2018/05/31 22:45:00            2018/05/31 22:45:02&lt;BR /&gt;
                        2018/05/31 23:00:01            2018/05/31 23:00:03&lt;BR /&gt;
                        2018/05/31 23:15:00            2018/05/31 23:15:01&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 19:48:14 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433881#M41500</guid>
      <dc:creator>abhi04</dc:creator>
      <dc:date>2020-09-29T19:48:14Z</dc:date>
    </item>
    <item>
      <title>Re: how to create the below mentioned table?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433882#M41501</link>
      <description>&lt;P&gt;Job_Name       StartTime                           EndTime                     Duration_Min    Duration_Sec&lt;BR /&gt;
 gc01iwcft      2018/05/31 22:45:00               2018/05/31 22:45:02&lt;BR /&gt;
                        2018/05/31 23:00:01                 2018/05/31 23:00:03&lt;BR /&gt;
                         2018/05/31 23:15:00                 2018/05/31 23:15:01&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 19:48:17 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433882#M41501</guid>
      <dc:creator>abhi04</dc:creator>
      <dc:date>2020-09-29T19:48:17Z</dc:date>
    </item>
    <item>
      <title>Re: how to create the below mentioned table?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433883#M41502</link>
      <description>&lt;P&gt;@ abhi04 - Are you trying to calculate difference between StartTime EndTime in Duration_Min Duration_Sec&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 19:48:20 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433883#M41502</guid>
      <dc:creator>Shan</dc:creator>
      <dc:date>2020-09-29T19:48:20Z</dc:date>
    </item>
    <item>
      <title>Re: how to create the below mentioned table?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433884#M41503</link>
      <description>&lt;P&gt;Yes shankarananth&lt;/P&gt;</description>
      <pubDate>Fri, 01 Jun 2018 10:09:53 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433884#M41503</guid>
      <dc:creator>abhi04</dc:creator>
      <dc:date>2018-06-01T10:09:53Z</dc:date>
    </item>
    <item>
      <title>Re: how to create the below mentioned table?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433885#M41504</link>
      <description>&lt;P&gt;@abhi04&lt;/P&gt;

&lt;P&gt;Try below query.   &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; |makeresults 
| eval timeDiffsec=strptime("2018/05/31 23:45:02","%Y/%m/%d %H:%M:%S")-strptime("2018/05/31 22:45:00", "%Y/%m/%d %H:%M:%S")
| eval Timediff_Mins=round((timeDiffsec/60),1)  
| eval Timediff_Hours=round((timeDiffsec/60/60),1)  
| table timeDiffsec Timediff_Mins Timediff_Hours
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I have used sample date and time value instead of it you can use your field. Eg &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| eval timeDiffsec=strptime(EndTime ,"%Y/%m/%d %H:%M:%S")-strptime(StartTime, "%Y/%m/%d %H:%M:%S")
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 01 Jun 2018 10:11:37 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433885#M41504</guid>
      <dc:creator>Shan</dc:creator>
      <dc:date>2018-06-01T10:11:37Z</dc:date>
    </item>
    <item>
      <title>Re: how to create the below mentioned table?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433886#M41505</link>
      <description>&lt;P&gt;@abhi04 you have only one Job_name. Are the remaining columns Multi Valued? Or did you just missed to copy the Job Names for each row?&lt;/P&gt;</description>
      <pubDate>Fri, 01 Jun 2018 10:13:25 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433886#M41505</guid>
      <dc:creator>niketn</dc:creator>
      <dc:date>2018-06-01T10:13:25Z</dc:date>
    </item>
    <item>
      <title>Re: how to create the below mentioned table?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433887#M41506</link>
      <description>&lt;P&gt;Only one job name with Other columns multi valued because this job ran multiple times and I want difference of each. &lt;/P&gt;</description>
      <pubDate>Fri, 01 Jun 2018 10:31:11 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433887#M41506</guid>
      <dc:creator>abhi04</dc:creator>
      <dc:date>2018-06-01T10:31:11Z</dc:date>
    </item>
    <item>
      <title>Re: how to create the below mentioned table?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433888#M41507</link>
      <description>&lt;P&gt;Well the above one is not working with the query I have used. below is the query I am using.&lt;/P&gt;

&lt;P&gt;index=auto_prod_iw* "/afiw/batch/scripts/gc01*.ksh" "Job gc01iwcft -" "started - time=" | dedup _raw |rex "\w+\/\w+\/\w+\/(?\w+).ksh" &lt;BR /&gt;
| eval StartTime=strftime(_time,"%Y/%m/%d %H:%M:%S") | append [| search index=auto_prod_iw* "/afiw/batch/scripts/gc01*.ksh" "Job gc01iwcft -" ("ended - time=" OR "ENDED - time")&lt;BR /&gt;
 | dedup _raw |rex "\w+\/\w+\/\w+\/(?\w+).ksh" | eval EndTime=strftime(_time,"%Y/%m/%d %H:%M:%S")] | transaction Job_Name  |dedup Job_Name |eval time_diff=strptime(EndTime,"%Y/%m/%d %H:%M:%S") -strptime(StartTime,"%Y/%m/%d %H:%M:%S") | table Job_Name StartTime EndTime time_diff&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 19:48:23 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433888#M41507</guid>
      <dc:creator>abhi04</dc:creator>
      <dc:date>2020-09-29T19:48:23Z</dc:date>
    </item>
    <item>
      <title>Re: how to create the below mentioned table?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433889#M41508</link>
      <description>&lt;P&gt;@abhi04 - I have tested below sample query for the scenario what you have mentioned. you can try from your end and let know.. &lt;/P&gt;</description>
      <pubDate>Fri, 01 Jun 2018 10:52:40 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433889#M41508</guid>
      <dc:creator>Shan</dc:creator>
      <dc:date>2018-06-01T10:52:40Z</dc:date>
    </item>
    <item>
      <title>Re: how to create the below mentioned table?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433890#M41509</link>
      <description>&lt;P&gt;Can you give existing query?&lt;/P&gt;

&lt;P&gt;If you need the difference of start time and end time for each occurrence of the Job run, you would need to have them as separate row(possibly just sort by Job Name and Start Time). &lt;/P&gt;

&lt;P&gt;If the data is having multivalued fields, then we have to come up with commands to spearate rows. If they are single value in raw events and they have become multivalue due to transforming command then it is better to correct the transforming command upfront.&lt;/P&gt;</description>
      <pubDate>Fri, 01 Jun 2018 10:54:17 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433890#M41509</guid>
      <dc:creator>niketn</dc:creator>
      <dc:date>2018-06-01T10:54:17Z</dc:date>
    </item>
    <item>
      <title>Re: how to create the below mentioned table?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433891#M41510</link>
      <description>&lt;P&gt;existing Query:&lt;/P&gt;

&lt;P&gt;index=auto_prod_iw* "/afiw/batch/scripts/gc01*.ksh" "Job gc01iwcft -" "started - time=" | dedup _raw |rex "\w+\/\w+\/\w+\/(?\w+).ksh" &lt;BR /&gt;
| eval StartTime=strftime(_time,"%Y/%m/%d %H:%M:%S") | append [| search index=auto_prod_iw* "/afiw/batch/scripts/gc01*.ksh" "Job gc01iwcft -" ("ended - time=" OR "ENDED - time")&lt;BR /&gt;
 | dedup _raw |rex "\w+\/\w+\/\w+\/(?\w+).ksh" | eval EndTime=strftime(_time,"%Y/%m/%d %H:%M:%S")] | transaction Job_Name  |dedup Job_Name &lt;BR /&gt;
 | table Job_Name StartTime EndTime duration  |eval Duration_Min= round((duration/60),2) | rename duration AS Duration_Sec&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 19:48:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433891#M41510</guid>
      <dc:creator>abhi04</dc:creator>
      <dc:date>2020-09-29T19:48:26Z</dc:date>
    </item>
    <item>
      <title>Re: how to create the below mentioned table?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433892#M41511</link>
      <description>&lt;P&gt;Can anyone help me on this?&lt;/P&gt;</description>
      <pubDate>Mon, 04 Jun 2018 13:49:00 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/how-to-create-the-below-mentioned-table/m-p/433892#M41511</guid>
      <dc:creator>abhi04</dc:creator>
      <dc:date>2018-06-04T13:49:00Z</dc:date>
    </item>
  </channel>
</rss>

