<?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 Extract value within quotes and plot on timechart in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Extract-value-within-quotes-and-plot-on-timechart/m-p/355058#M105047</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;I am very new to splunk and i have data like this below:&lt;/P&gt;

&lt;P&gt;"salary": "2000"&lt;/P&gt;

&lt;P&gt;I have 1000's of events like this, I would like to extract only the integer 2000 and plot the value on timechart.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;source="tcp:8050"  | search salary| rex _raw=".*(?P&amp;lt;sal&amp;gt;\d+).*" | timechart count as "SAL"
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;The above search is only returning the number of events having salary but not returning the actual value of 2000.&lt;BR /&gt;
Requests help to achieve this!!!&lt;BR /&gt;
Thanks!!&lt;/P&gt;</description>
    <pubDate>Fri, 22 Sep 2017 16:55:34 GMT</pubDate>
    <dc:creator>skenkere</dc:creator>
    <dc:date>2017-09-22T16:55:34Z</dc:date>
    <item>
      <title>Extract value within quotes and plot on timechart</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extract-value-within-quotes-and-plot-on-timechart/m-p/355058#M105047</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;I am very new to splunk and i have data like this below:&lt;/P&gt;

&lt;P&gt;"salary": "2000"&lt;/P&gt;

&lt;P&gt;I have 1000's of events like this, I would like to extract only the integer 2000 and plot the value on timechart.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;source="tcp:8050"  | search salary| rex _raw=".*(?P&amp;lt;sal&amp;gt;\d+).*" | timechart count as "SAL"
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;The above search is only returning the number of events having salary but not returning the actual value of 2000.&lt;BR /&gt;
Requests help to achieve this!!!&lt;BR /&gt;
Thanks!!&lt;/P&gt;</description>
      <pubDate>Fri, 22 Sep 2017 16:55:34 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extract-value-within-quotes-and-plot-on-timechart/m-p/355058#M105047</guid>
      <dc:creator>skenkere</dc:creator>
      <dc:date>2017-09-22T16:55:34Z</dc:date>
    </item>
    <item>
      <title>Re: Extract value within quotes and plot on timechart</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extract-value-within-quotes-and-plot-on-timechart/m-p/355059#M105048</link>
      <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/71022"&gt;@skenkere&lt;/a&gt;&lt;BR /&gt;
try this,&lt;/P&gt;

&lt;P&gt;your search here | rex field=_raw "\"salary\":\s+\"(?P&amp;lt;\d+&amp;gt;)\"" | timechart  count by sal_value&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 15:51:02 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extract-value-within-quotes-and-plot-on-timechart/m-p/355059#M105048</guid>
      <dc:creator>sbbadri</dc:creator>
      <dc:date>2020-09-29T15:51:02Z</dc:date>
    </item>
  </channel>
</rss>

