<?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: Restrict timechart to business hours in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Restrict-timechart-to-business-hours/m-p/376122#M168124</link>
    <description>&lt;P&gt;Yea, timechart will increment dynamically or based on the &lt;CODE&gt;span&lt;/CODE&gt; attribute in the rendering. But you might have to avoid timechart to avoid the unwanted time periods. Therefore, you're essentially just doing what @akocak described: making a generic chart for which you happen to have the x-axis as time, but Splunk just treats it like an arbitrary value list.&lt;/P&gt;</description>
    <pubDate>Fri, 27 Jul 2018 12:30:55 GMT</pubDate>
    <dc:creator>sloshburch</dc:creator>
    <dc:date>2018-07-27T12:30:55Z</dc:date>
    <item>
      <title>Restrict timechart to business hours</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Restrict-timechart-to-business-hours/m-p/376120#M168122</link>
      <description>&lt;P&gt;I am trying to create a timechart to count data for 7 days during business hours. I have the search working fine my problem is the user does not want to see business hours on the x-axis.&lt;/P&gt;

&lt;P&gt;sample&lt;BR /&gt;
    index=_internal|bucket _time span=1h|where date_hour&amp;gt;=8 and date_hour&amp;lt;16 |timechart count by sourcetype&lt;BR /&gt;
&lt;IMG src="https://community.splunk.com/storage/temp/253589-screen-shot-2018-07-26-at-105200-am.png" alt="alt text" /&gt;&lt;/P&gt;

&lt;P&gt;I do not want to make it continuous since the users assume the connection represents real values. Im looking to only show 8am-4pm each day on the x-axis.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 20:39:29 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Restrict-timechart-to-business-hours/m-p/376120#M168122</guid>
      <dc:creator>jmerry_splunk</dc:creator>
      <dc:date>2020-09-29T20:39:29Z</dc:date>
    </item>
    <item>
      <title>Re: Restrict timechart to business hours</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Restrict-timechart-to-business-hours/m-p/376121#M168123</link>
      <description>&lt;P&gt;it doesn't give you exactly what you need. however, representation wise, I believe this is not too far from what you need:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=_internal 
| bucket _time span=1h 
| where date_hour&amp;gt;=8 and date_hour&amp;lt;16 
| sort date_mday
| eval mhour = date_wday.":".date_hour
| chart count over mhour by sourcetype
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;You should also note that, timechart command would have its own span and I am not sure how 1h would work in weekly chart. &lt;/P&gt;</description>
      <pubDate>Thu, 26 Jul 2018 15:44:59 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Restrict-timechart-to-business-hours/m-p/376121#M168123</guid>
      <dc:creator>akocak</dc:creator>
      <dc:date>2018-07-26T15:44:59Z</dc:date>
    </item>
    <item>
      <title>Re: Restrict timechart to business hours</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Restrict-timechart-to-business-hours/m-p/376122#M168124</link>
      <description>&lt;P&gt;Yea, timechart will increment dynamically or based on the &lt;CODE&gt;span&lt;/CODE&gt; attribute in the rendering. But you might have to avoid timechart to avoid the unwanted time periods. Therefore, you're essentially just doing what @akocak described: making a generic chart for which you happen to have the x-axis as time, but Splunk just treats it like an arbitrary value list.&lt;/P&gt;</description>
      <pubDate>Fri, 27 Jul 2018 12:30:55 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Restrict-timechart-to-business-hours/m-p/376122#M168124</guid>
      <dc:creator>sloshburch</dc:creator>
      <dc:date>2018-07-27T12:30:55Z</dc:date>
    </item>
    <item>
      <title>Re: Restrict timechart to business hours</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Restrict-timechart-to-business-hours/m-p/376123#M168125</link>
      <description>&lt;P&gt;When you say "the user does not want to see business hours", what do you mean?&lt;/P&gt;</description>
      <pubDate>Fri, 27 Jul 2018 14:27:49 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Restrict-timechart-to-business-hours/m-p/376123#M168125</guid>
      <dc:creator>DalJeanis</dc:creator>
      <dc:date>2018-07-27T14:27:49Z</dc:date>
    </item>
  </channel>
</rss>

