<?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 Parsing a Log File in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/Parsing-a-Log-File/m-p/79072#M16207</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;I have a file with the below format :&lt;/P&gt;

&lt;P&gt;CustID=129857 CusTime=2012-04-04 CusName=John, Doe CustState=NewJersey CustProduct=Cellphone RecName=Peter, Adams RecLoc=Mumbai Corp RecEmail=&lt;A href="mailto:Peter.adams@yahoo.com" target="_blank"&gt;Peter.adams@yahoo.com&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;CustID=129857 CusTime=2012-04-04 CusName=John, Doe CustState=NewJersey CustProduct=LanLine RecName=Peter_1, Adams_1 RecLoc=Bangalore Corp RecEmail=&lt;A href="mailto:Peter_1.adams_1@yahoo.com" target="_blank"&gt;Peter_1.adams_1@yahoo.com&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;CustID=129857 CusTime=2012-04-04 CusName=John, Doe CustState=California CustProduct=Cellphone RecName=Peter, Adams RecLoc=Mumbai Corp RecEmail=&lt;A href="mailto:Peter.adams@yahoo.com" target="_blank"&gt;Peter.adams@yahoo.com&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;CustID=129859 CusTime=2012-04-04 CusName=Peter, Doe CustState=NewJersey CustProduct=Cellphone RecName=John, Adams RecLoc=Mumbai Corp RecEmail=&lt;A href="mailto:Peter.adams@yahoo.com" target="_blank"&gt;Peter.adams@yahoo.com&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;I want in a graphical / report format for each CustID the CusName and the different RecName he has been dealing with. And if the RecLoc is Mumbai Corp than categorize that as LOCAL else EXTERNAL.&lt;/P&gt;

&lt;P&gt;So basically the output should be :&lt;/P&gt;

&lt;P&gt;Cust ID   CusName    Count      RecName        RecLoc            Type &lt;BR /&gt;
129857   John, Doe      2     Peter, Adams     Mumbai Corp      LOCAL&lt;BR /&gt;
129857   John, Doe      1     Peter_1,Adams_1  Bangalore Corp   External&lt;BR /&gt;&lt;BR /&gt;
129859   Peter, Doe     1     John, Adams      Mumbai Corp      LOCAL&lt;/P&gt;

&lt;P&gt;Pls let me know if this is possible and if you can pls provide a sample code I can try.&lt;/P&gt;

&lt;P&gt;Thank you&lt;/P&gt;</description>
    <pubDate>Mon, 28 Sep 2020 11:57:52 GMT</pubDate>
    <dc:creator>kshahborr99</dc:creator>
    <dc:date>2020-09-28T11:57:52Z</dc:date>
    <item>
      <title>Parsing a Log File</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Parsing-a-Log-File/m-p/79072#M16207</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;I have a file with the below format :&lt;/P&gt;

&lt;P&gt;CustID=129857 CusTime=2012-04-04 CusName=John, Doe CustState=NewJersey CustProduct=Cellphone RecName=Peter, Adams RecLoc=Mumbai Corp RecEmail=&lt;A href="mailto:Peter.adams@yahoo.com" target="_blank"&gt;Peter.adams@yahoo.com&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;CustID=129857 CusTime=2012-04-04 CusName=John, Doe CustState=NewJersey CustProduct=LanLine RecName=Peter_1, Adams_1 RecLoc=Bangalore Corp RecEmail=&lt;A href="mailto:Peter_1.adams_1@yahoo.com" target="_blank"&gt;Peter_1.adams_1@yahoo.com&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;CustID=129857 CusTime=2012-04-04 CusName=John, Doe CustState=California CustProduct=Cellphone RecName=Peter, Adams RecLoc=Mumbai Corp RecEmail=&lt;A href="mailto:Peter.adams@yahoo.com" target="_blank"&gt;Peter.adams@yahoo.com&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;CustID=129859 CusTime=2012-04-04 CusName=Peter, Doe CustState=NewJersey CustProduct=Cellphone RecName=John, Adams RecLoc=Mumbai Corp RecEmail=&lt;A href="mailto:Peter.adams@yahoo.com" target="_blank"&gt;Peter.adams@yahoo.com&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;I want in a graphical / report format for each CustID the CusName and the different RecName he has been dealing with. And if the RecLoc is Mumbai Corp than categorize that as LOCAL else EXTERNAL.&lt;/P&gt;

&lt;P&gt;So basically the output should be :&lt;/P&gt;

&lt;P&gt;Cust ID   CusName    Count      RecName        RecLoc            Type &lt;BR /&gt;
129857   John, Doe      2     Peter, Adams     Mumbai Corp      LOCAL&lt;BR /&gt;
129857   John, Doe      1     Peter_1,Adams_1  Bangalore Corp   External&lt;BR /&gt;&lt;BR /&gt;
129859   Peter, Doe     1     John, Adams      Mumbai Corp      LOCAL&lt;/P&gt;

&lt;P&gt;Pls let me know if this is possible and if you can pls provide a sample code I can try.&lt;/P&gt;

&lt;P&gt;Thank you&lt;/P&gt;</description>
      <pubDate>Mon, 28 Sep 2020 11:57:52 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Parsing-a-Log-File/m-p/79072#M16207</guid>
      <dc:creator>kshahborr99</dc:creator>
      <dc:date>2020-09-28T11:57:52Z</dc:date>
    </item>
    <item>
      <title>Re: Parsing a Log File</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Parsing-a-Log-File/m-p/79073#M16208</link>
      <description>&lt;P&gt;Try this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;...&amp;lt;your data search&amp;gt; | eval Type=if(RecLoc="Mumbai Corp", "LOCAL", "External") | stats count as Count by CusName, RecName, RecLoc | fields CustID, CusName, RecName, Count, RecLoc, Type
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Let me know if that gets you close.&lt;/P&gt;</description>
      <pubDate>Wed, 20 Jun 2012 02:26:16 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Parsing-a-Log-File/m-p/79073#M16208</guid>
      <dc:creator>Lamar</dc:creator>
      <dc:date>2012-06-20T02:26:16Z</dc:date>
    </item>
  </channel>
</rss>

