<?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 combine two fields into one to run a stats count search? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-combine-two-fields-into-one-to-run-a-stats-count-search/m-p/204125#M59311</link>
    <description>&lt;P&gt;hey thanks for answer  looks like its not working, let me more clear about the problem, &lt;BR /&gt;
One event has info what i need say FiledA   which i extracted using splunk from raw data , will have valuses like trans1 ,trans2.... And ALSO say one value like REST , AND filedB which i extracted will have again tans1.trans2....AND say NOTSET , so date will be like Flied A entries which has REST , as a value , will be having m trans1..etc in FliedB&lt;BR /&gt;
siminalry NOTSET in filed value will have values of trans1 etc in FiledA &lt;BR /&gt;
So here am only intrested in trasn1,trans2... &lt;/P&gt;</description>
    <pubDate>Fri, 15 Apr 2016 17:20:09 GMT</pubDate>
    <dc:creator>reachskhm</dc:creator>
    <dc:date>2016-04-15T17:20:09Z</dc:date>
    <item>
      <title>How to combine two fields into one to run a stats count search?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-combine-two-fields-into-one-to-run-a-stats-count-search/m-p/204123#M59309</link>
      <description>&lt;P&gt;I have log events which are little different, but each event has a unique name which I am interested in. However, this unique name is not in one field. &lt;/P&gt;

&lt;P&gt;Say I have names of transactions which I want get count of. Let's say transaction names are tran1, tran2, tran3, tran4. This info of the name is in one event in fieldA and in other event in fieldB. How do I combine these 2 fields to get a field so that I can perform stats on count and response time.&lt;BR /&gt;
To be more specific, fieldA and fieldB will have tran1 or tran2 etc either in fieldA or in fieldB, I would like to search the count by tran1 and tran2  etc.&lt;/P&gt;

&lt;P&gt;thanks in advance&lt;/P&gt;</description>
      <pubDate>Fri, 15 Apr 2016 16:34:04 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-combine-two-fields-into-one-to-run-a-stats-count-search/m-p/204123#M59309</guid>
      <dc:creator>reachskhm</dc:creator>
      <dc:date>2016-04-15T16:34:04Z</dc:date>
    </item>
    <item>
      <title>Re: How to combine two fields into one to run a stats count search?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-combine-two-fields-into-one-to-run-a-stats-count-search/m-p/204124#M59310</link>
      <description>&lt;P&gt;Like this&lt;BR /&gt;
    .... | eval fldname=coalesce(fieldA, fieldB) | stats count by fldname&lt;/P&gt;</description>
      <pubDate>Fri, 15 Apr 2016 16:58:04 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-combine-two-fields-into-one-to-run-a-stats-count-search/m-p/204124#M59310</guid>
      <dc:creator>sundareshr</dc:creator>
      <dc:date>2016-04-15T16:58:04Z</dc:date>
    </item>
    <item>
      <title>Re: How to combine two fields into one to run a stats count search?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-combine-two-fields-into-one-to-run-a-stats-count-search/m-p/204125#M59311</link>
      <description>&lt;P&gt;hey thanks for answer  looks like its not working, let me more clear about the problem, &lt;BR /&gt;
One event has info what i need say FiledA   which i extracted using splunk from raw data , will have valuses like trans1 ,trans2.... And ALSO say one value like REST , AND filedB which i extracted will have again tans1.trans2....AND say NOTSET , so date will be like Flied A entries which has REST , as a value , will be having m trans1..etc in FliedB&lt;BR /&gt;
siminalry NOTSET in filed value will have values of trans1 etc in FiledA &lt;BR /&gt;
So here am only intrested in trasn1,trans2... &lt;/P&gt;</description>
      <pubDate>Fri, 15 Apr 2016 17:20:09 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-combine-two-fields-into-one-to-run-a-stats-count-search/m-p/204125#M59311</guid>
      <dc:creator>reachskhm</dc:creator>
      <dc:date>2016-04-15T17:20:09Z</dc:date>
    </item>
    <item>
      <title>Re: How to combine two fields into one to run a stats count search?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-combine-two-fields-into-one-to-run-a-stats-count-search/m-p/204126#M59312</link>
      <description>&lt;P&gt;Not sure I understand. Can you put the sample is a table form. A few rows with field names and values?&lt;/P&gt;</description>
      <pubDate>Sat, 16 Apr 2016 00:17:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-combine-two-fields-into-one-to-run-a-stats-count-search/m-p/204126#M59312</guid>
      <dc:creator>sundareshr</dc:creator>
      <dc:date>2016-04-16T00:17:26Z</dc:date>
    </item>
    <item>
      <title>Re: How to combine two fields into one to run a stats count search?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-combine-two-fields-into-one-to-run-a-stats-count-search/m-p/204127#M59313</link>
      <description>&lt;P&gt;Below is the example of the events in table &lt;/P&gt;

&lt;P&gt;So when you a stats i need like trans1 as 4 , trans2 as 5 , trans3 as 1 , the count combined from filed a and field b  ingoring ERR and Res from these fileds. and also i want o do some avg on resptimeinsecs accordingly.. thanks in advance.&lt;/P&gt;

&lt;P&gt;Event   Flied A FliedB  Source  resptimeinsecs&lt;BR /&gt;
1       Trans1  Res     CP      10&lt;BR /&gt;
2       Trans2  Res     CP      45&lt;BR /&gt;
3       Err     Trans3  CP      67&lt;BR /&gt;
4       Trans1  Res     CP      91&lt;BR /&gt;
5       Err     Trans2  CP      78&lt;BR /&gt;
6       Trans2  Res     CP      86&lt;BR /&gt;
7       Trans1  Res     CP      90&lt;BR /&gt;
8       Trans2  Res     CP      86&lt;BR /&gt;
9       Err     Trans1  CP      90&lt;BR /&gt;
10      Trans2  Res     CP      86&lt;/P&gt;</description>
      <pubDate>Tue, 19 Apr 2016 16:01:59 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-combine-two-fields-into-one-to-run-a-stats-count-search/m-p/204127#M59313</guid>
      <dc:creator>reachskhm</dc:creator>
      <dc:date>2016-04-19T16:01:59Z</dc:date>
    </item>
  </channel>
</rss>

