<?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: How to range columns and rows ? in Knowledge Management</title>
    <link>https://community.splunk.com/t5/Knowledge-Management/How-to-range-columns-and-rows/m-p/317653#M5291</link>
    <description>&lt;P&gt;Give this a try&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;(index=index1 sourcetype=index1_log) OR (index=index2 sourcetype=index2_log) 
| rex field=_raw "(?&amp;lt;Message&amp;gt;(exception|message)\s\w+\s\w+)" 
|stats count as "Hit Count" by Message
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Tue, 11 Apr 2017 16:25:21 GMT</pubDate>
    <dc:creator>somesoni2</dc:creator>
    <dc:date>2017-04-11T16:25:21Z</dc:date>
    <item>
      <title>How to range columns and rows ?</title>
      <link>https://community.splunk.com/t5/Knowledge-Management/How-to-range-columns-and-rows/m-p/317645#M5283</link>
      <description>&lt;P&gt;I have the following result from Splunk Query using appCols because same logs always has different events with different message&lt;/P&gt;

&lt;P&gt;message1 or message2 just a name..&lt;/P&gt;

&lt;P&gt;Message   Count1    Message2           count2 &lt;BR /&gt;
hello           5         hi                             10&lt;/P&gt;

&lt;P&gt;Output i am looking is :&lt;BR /&gt;
Message  count  --&amp;lt; Header Fields&amp;gt;&lt;BR /&gt;
hello         5&lt;BR /&gt;&lt;BR /&gt;
hi                10 &lt;/P&gt;</description>
      <pubDate>Mon, 10 Apr 2017 21:30:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Knowledge-Management/How-to-range-columns-and-rows/m-p/317645#M5283</guid>
      <dc:creator>jw44250</dc:creator>
      <dc:date>2017-04-10T21:30:24Z</dc:date>
    </item>
    <item>
      <title>Re: How to range columns and rows ?</title>
      <link>https://community.splunk.com/t5/Knowledge-Management/How-to-range-columns-and-rows/m-p/317646#M5284</link>
      <description>&lt;P&gt;Instead of appendcols, you should use just append. Also, remember to rename the fields in 2nd search (Message2 and count2) same as first search.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;search 1 | table Message Count
| append [search 2 | table Message2 Count2 | rename Message2 as Message Count2 as Count ]
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;See this to know difference between append and appendcols.&lt;BR /&gt;
&lt;A href="https://answers.splunk.com/answers/144351/what-are-the-differences-between-append-appendpipe.html"&gt;https://answers.splunk.com/answers/144351/what-are-the-differences-between-append-appendpipe.html&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 10 Apr 2017 21:33:44 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Knowledge-Management/How-to-range-columns-and-rows/m-p/317646#M5284</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2017-04-10T21:33:44Z</dc:date>
    </item>
    <item>
      <title>Re: How to range columns and rows ?</title>
      <link>https://community.splunk.com/t5/Knowledge-Management/How-to-range-columns-and-rows/m-p/317647#M5285</link>
      <description>&lt;P&gt;it is same index. but i have to extract different fields each time from events.. since the events returns has different message&lt;/P&gt;</description>
      <pubDate>Mon, 10 Apr 2017 21:56:13 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Knowledge-Management/How-to-range-columns-and-rows/m-p/317647#M5285</guid>
      <dc:creator>jw44250</dc:creator>
      <dc:date>2017-04-10T21:56:13Z</dc:date>
    </item>
    <item>
      <title>Re: How to range columns and rows ?</title>
      <link>https://community.splunk.com/t5/Knowledge-Management/How-to-range-columns-and-rows/m-p/317648#M5286</link>
      <description>&lt;P&gt;i using transport i didnt work ..&lt;/P&gt;</description>
      <pubDate>Mon, 10 Apr 2017 21:57:39 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Knowledge-Management/How-to-range-columns-and-rows/m-p/317648#M5286</guid>
      <dc:creator>jw44250</dc:creator>
      <dc:date>2017-04-10T21:57:39Z</dc:date>
    </item>
    <item>
      <title>Re: How to range columns and rows ?</title>
      <link>https://community.splunk.com/t5/Knowledge-Management/How-to-range-columns-and-rows/m-p/317649#M5287</link>
      <description>&lt;P&gt;Thanks it did work.&lt;/P&gt;</description>
      <pubDate>Mon, 10 Apr 2017 22:03:11 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Knowledge-Management/How-to-range-columns-and-rows/m-p/317649#M5287</guid>
      <dc:creator>jw44250</dc:creator>
      <dc:date>2017-04-10T22:03:11Z</dc:date>
    </item>
    <item>
      <title>Re: How to range columns and rows ?</title>
      <link>https://community.splunk.com/t5/Knowledge-Management/How-to-range-columns-and-rows/m-p/317650#M5288</link>
      <description>&lt;P&gt;Glad it's working for you. If it's same index, you probably don't need a subsearch. If you could share you search, we can look at it to see if both searches can be merged into one for better performance.&lt;/P&gt;</description>
      <pubDate>Mon, 10 Apr 2017 22:22:17 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Knowledge-Management/How-to-range-columns-and-rows/m-p/317650#M5288</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2017-04-10T22:22:17Z</dc:date>
    </item>
    <item>
      <title>Re: How to range columns and rows ?</title>
      <link>https://community.splunk.com/t5/Knowledge-Management/How-to-range-columns-and-rows/m-p/317651#M5289</link>
      <description>&lt;P&gt;Here is the Splunk Query..&lt;/P&gt;

&lt;P&gt;index=index1 sourcetype=index1_log | rex field=_raw "(?exception\s\w+\s\w+)" |stats count by Message| table Message count  | append&lt;BR /&gt;
[search index=index2 sourcetype=index2_log | rex field=_raw "(?message\s\w+\s\w+)" |stats count as count1 by message| table message count1 |rename message as Message count1 as count] | rename count as "Hit Count"&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 13:35:52 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Knowledge-Management/How-to-range-columns-and-rows/m-p/317651#M5289</guid>
      <dc:creator>jw44250</dc:creator>
      <dc:date>2020-09-29T13:35:52Z</dc:date>
    </item>
    <item>
      <title>Re: How to range columns and rows ?</title>
      <link>https://community.splunk.com/t5/Knowledge-Management/How-to-range-columns-and-rows/m-p/317652#M5290</link>
      <description>&lt;P&gt;When adding timechart span=3h count usenull=f useother=f into both indexes getting error :- please rename count columns.&lt;/P&gt;</description>
      <pubDate>Tue, 11 Apr 2017 16:21:02 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Knowledge-Management/How-to-range-columns-and-rows/m-p/317652#M5290</guid>
      <dc:creator>jw44250</dc:creator>
      <dc:date>2017-04-11T16:21:02Z</dc:date>
    </item>
    <item>
      <title>Re: How to range columns and rows ?</title>
      <link>https://community.splunk.com/t5/Knowledge-Management/How-to-range-columns-and-rows/m-p/317653#M5291</link>
      <description>&lt;P&gt;Give this a try&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;(index=index1 sourcetype=index1_log) OR (index=index2 sourcetype=index2_log) 
| rex field=_raw "(?&amp;lt;Message&amp;gt;(exception|message)\s\w+\s\w+)" 
|stats count as "Hit Count" by Message
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 11 Apr 2017 16:25:21 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Knowledge-Management/How-to-range-columns-and-rows/m-p/317653#M5291</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2017-04-11T16:25:21Z</dc:date>
    </item>
    <item>
      <title>Re: How to range columns and rows ?</title>
      <link>https://community.splunk.com/t5/Knowledge-Management/How-to-range-columns-and-rows/m-p/317654#M5292</link>
      <description>&lt;P&gt;YOu're getting that in same query? &lt;/P&gt;</description>
      <pubDate>Tue, 11 Apr 2017 16:25:47 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Knowledge-Management/How-to-range-columns-and-rows/m-p/317654#M5292</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2017-04-11T16:25:47Z</dc:date>
    </item>
    <item>
      <title>Re: How to range columns and rows ?</title>
      <link>https://community.splunk.com/t5/Knowledge-Management/How-to-range-columns-and-rows/m-p/317655#M5293</link>
      <description>&lt;P&gt;let me tried it..thanks&lt;/P&gt;</description>
      <pubDate>Tue, 11 Apr 2017 16:40:44 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Knowledge-Management/How-to-range-columns-and-rows/m-p/317655#M5293</guid>
      <dc:creator>jw44250</dc:creator>
      <dc:date>2017-04-11T16:40:44Z</dc:date>
    </item>
  </channel>
</rss>

