<?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: time span query in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/time-span-query/m-p/651739#M225291</link>
    <description>&lt;P&gt;i get an error message with that&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Error in 'timewrap' command: Option 'span=1y' is invalid.&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Mon, 24 Jul 2023 09:39:19 GMT</pubDate>
    <dc:creator>PaulaCom</dc:creator>
    <dc:date>2023-07-24T09:39:19Z</dc:date>
    <item>
      <title>time span query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/time-span-query/m-p/651719#M225287</link>
      <description>&lt;P&gt;Hi All&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'd like some help please with a query thats been asked of me and its a little out of my depth&amp;nbsp;&lt;/P&gt;&lt;P&gt;the current below query shows year total of helpdesk calls by year&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="PaulaCom_0-1690188777402.png" style="width: 400px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/26426i585FCD669479DDEE/image-size/medium?v=v2&amp;amp;px=400" role="button" title="PaulaCom_0-1690188777402.png" alt="PaulaCom_0-1690188777402.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;index=mmuh_helpdesk sourcetype=mmuh_helpdesk_json&lt;BR /&gt;| dedup id&lt;BR /&gt;| fillnull value=NULL&lt;BR /&gt;| search "problemtype.detailDisplayName"!=*AGRESSO*&lt;BR /&gt;| eval problem_detail='problemtype.detailDisplayName'&lt;BR /&gt;| eval problem_detail=replace(problem_detail, "&amp;amp;#8226","")&lt;BR /&gt;| eval problem_detail=replace(problem_detail, ";","|")&lt;BR /&gt;| eval techGroupLevel = 'techGroupLevel.levelName'&lt;BR /&gt;| eval techGroupLevel = replace(techGroupLevel, "&amp;amp;nbsp;"," ")&lt;BR /&gt;| eval techGroupLevel = replace(techGroupLevel, " ","")&lt;BR /&gt;| eval techGroupLevel = replace(techGroupLevel, "Level"," Level")&lt;BR /&gt;| eval location_Name = 'location.locationName'&lt;BR /&gt;| eval status = 'statustype.statusTypeName'&lt;BR /&gt;| eval priority = 'prioritytype.priorityTypeName'&lt;BR /&gt;| eval techGroupId = 'techGroupLevel.id'&lt;BR /&gt;| eval tech_Name = 'clientTech.displayName'&lt;BR /&gt;| top limit=20 date_year&lt;BR /&gt;| search date_year IN(2020,2021,2022,2023)&lt;BR /&gt;| eval sort=case(date_year=="2020", "02", date_year=="2021","03", date_year=="2022","04", date_year=="2023","05")&lt;BR /&gt;| sort sort&lt;BR /&gt;| fields - sort&lt;BR /&gt;| fields - percent&lt;BR /&gt;| eval Year=case(date_year=="2020", "Y 2020", date_year=="2021", "Y 2021", date_year=="2022", "Y 2022", date_year=="2023", "Y 2023")&lt;BR /&gt;| table Year count&lt;/P&gt;&lt;P&gt;i would now like to show years only 2021 and 2022 in line chart&amp;nbsp;&lt;/P&gt;&lt;P&gt;but ... i would like each year to have a separate line&amp;nbsp;&lt;/P&gt;&lt;P&gt;if possible i'd like the time span for each year to be broken into a month&amp;nbsp;&lt;/P&gt;&lt;P&gt;i can get this with the time picker (previous year chosen) and following query below for 2022&lt;/P&gt;&lt;P&gt;index=mmuh_helpdesk sourcetype=mmuh_helpdesk_json&lt;BR /&gt;| dedup id&lt;BR /&gt;| fillnull value=NULL&lt;BR /&gt;| search "problemtype.detailDisplayName"!=*AGRESSO*&lt;BR /&gt;| eval problem_detail='problemtype.detailDisplayName'&lt;BR /&gt;| eval problem_detail=replace(problem_detail, "&amp;amp;#8226","")&lt;BR /&gt;| eval problem_detail=replace(problem_detail, ";","|")&lt;BR /&gt;| eval techGroupLevel = 'techGroupLevel.levelName'&lt;BR /&gt;| eval techGroupLevel = replace(techGroupLevel, "&amp;amp;nbsp;"," ")&lt;BR /&gt;| eval techGroupLevel = replace(techGroupLevel, " ","")&lt;BR /&gt;| eval techGroupLevel = replace(techGroupLevel, "Level"," Level")&lt;BR /&gt;| eval location_Name = 'location.locationName'&lt;BR /&gt;| eval status = 'statustype.statusTypeName'&lt;BR /&gt;| eval priority = 'prioritytype.priorityTypeName'&lt;BR /&gt;| eval techGroupId = 'techGroupLevel.id'&lt;BR /&gt;| eval tech_Name = 'clientTech.displayName'&lt;BR /&gt;| timechart span=1mon count(id)&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="PaulaCom_1-1690189256677.png" style="width: 400px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/26427iFACB1AB42BEC89C2/image-size/medium?v=v2&amp;amp;px=400" role="button" title="PaulaCom_1-1690189256677.png" alt="PaulaCom_1-1690189256677.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;how can i get both years show ?&lt;/P&gt;&lt;P&gt;thank you&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 24 Jul 2023 09:04:36 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/time-span-query/m-p/651719#M225287</guid>
      <dc:creator>PaulaCom</dc:creator>
      <dc:date>2023-07-24T09:04:36Z</dc:date>
    </item>
    <item>
      <title>Re: time span query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/time-span-query/m-p/651727#M225288</link>
      <description>&lt;P&gt;Try something like this&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=mmuh_helpdesk sourcetype=mmuh_helpdesk_json earliest=-2y@y latest=@y
| dedup id
| fillnull value=NULL
| search "problemtype.detailDisplayName"!=*AGRESSO*
| eval problem_detail='problemtype.detailDisplayName'
| eval problem_detail=replace(problem_detail, "&amp;amp;#8226","")
| eval problem_detail=replace(problem_detail, ";","|")
| eval techGroupLevel = 'techGroupLevel.levelName'
| eval techGroupLevel = replace(techGroupLevel, "&amp;amp;nbsp;"," ")
| eval techGroupLevel = replace(techGroupLevel, " ","")
| eval techGroupLevel = replace(techGroupLevel, "Level"," Level")
| eval location_Name = 'location.locationName'
| eval status = 'statustype.statusTypeName'
| eval priority = 'prioritytype.priorityTypeName'
| eval techGroupId = 'techGroupLevel.id'
| eval tech_Name = 'clientTech.displayName'
| timechart span=1mon count(id)
| timewrap 1y&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 24 Jul 2023 12:27:56 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/time-span-query/m-p/651727#M225288</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2023-07-24T12:27:56Z</dc:date>
    </item>
    <item>
      <title>Re: time span query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/time-span-query/m-p/651739#M225291</link>
      <description>&lt;P&gt;i get an error message with that&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Error in 'timewrap' command: Option 'span=1y' is invalid.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 24 Jul 2023 09:39:19 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/time-span-query/m-p/651739#M225291</guid>
      <dc:creator>PaulaCom</dc:creator>
      <dc:date>2023-07-24T09:39:19Z</dc:date>
    </item>
    <item>
      <title>Re: time span query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/time-span-query/m-p/651747#M225295</link>
      <description>&lt;P&gt;Try without span=&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| timewrap 1y&lt;/LI-CODE&gt;</description>
      <pubDate>Mon, 24 Jul 2023 10:06:00 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/time-span-query/m-p/651747#M225295</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2023-07-24T10:06:00Z</dc:date>
    </item>
    <item>
      <title>Re: time span query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/time-span-query/m-p/651757#M225300</link>
      <description>&lt;P&gt;thank you that worked&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 24 Jul 2023 11:30:55 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/time-span-query/m-p/651757#M225300</guid>
      <dc:creator>PaulaCom</dc:creator>
      <dc:date>2023-07-24T11:30:55Z</dc:date>
    </item>
    <item>
      <title>Re: time span query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/time-span-query/m-p/651760#M225301</link>
      <description>&lt;P&gt;I updated my response accordingly.&lt;/P&gt;</description>
      <pubDate>Mon, 24 Jul 2023 12:28:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/time-span-query/m-p/651760#M225301</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2023-07-24T12:28:32Z</dc:date>
    </item>
  </channel>
</rss>

