<?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: perl script in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/perl-script/m-p/46377#M11097</link>
    <description>&lt;P&gt;This is ideal for a custom search command in which you can manipulate the data and insert knowledge dynamically. This, however, needs to be done in Python and will require you to follow the rules of integration documented &lt;A href="http://docs.splunk.com/Documentation/Splunk/5.0.2/AdvancedDev/SearchScripts"&gt;here&lt;/A&gt;.&lt;/P&gt;

&lt;P&gt;Please see the example in the link provided. In the end, however, it should look something like this:&lt;/P&gt;

&lt;HR /&gt;

&lt;PRE&gt;&lt;CODE&gt;import sys
import splunk.Intersplunk
import string

results = splunk.Intersplunk.readResults(None, None, True)

for event in results:

    """ data analysis and calculations here """

    ...    

    """ add new field 'newname' """
    event['newname'] = "".join(newval)

splunk.Intersplunk.outputResults(results)
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;HR /&gt;

&lt;P&gt;I hope this helps.&lt;/P&gt;</description>
    <pubDate>Mon, 27 May 2013 19:27:40 GMT</pubDate>
    <dc:creator>Gilberto_Castil</dc:creator>
    <dc:date>2013-05-27T19:27:40Z</dc:date>
    <item>
      <title>perl script</title>
      <link>https://community.splunk.com/t5/Splunk-Search/perl-script/m-p/46376#M11096</link>
      <description>&lt;P&gt;Hello all,&lt;/P&gt;

&lt;P&gt;I need to create multiple eval fields like this old question:&lt;BR /&gt;
&lt;A href="http://splunk-base.splunk.com/answers/81708/create-multiple-eval-fields-with-wilcards" title="create-multiple-eval-fields-with-wilcards"&gt;create-multiple-eval-fields-with-wilcards&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;Is it possible with a perl script in splunk?&lt;/P&gt;</description>
      <pubDate>Mon, 27 May 2013 09:55:06 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/perl-script/m-p/46376#M11096</guid>
      <dc:creator>Fabien05</dc:creator>
      <dc:date>2013-05-27T09:55:06Z</dc:date>
    </item>
    <item>
      <title>Re: perl script</title>
      <link>https://community.splunk.com/t5/Splunk-Search/perl-script/m-p/46377#M11097</link>
      <description>&lt;P&gt;This is ideal for a custom search command in which you can manipulate the data and insert knowledge dynamically. This, however, needs to be done in Python and will require you to follow the rules of integration documented &lt;A href="http://docs.splunk.com/Documentation/Splunk/5.0.2/AdvancedDev/SearchScripts"&gt;here&lt;/A&gt;.&lt;/P&gt;

&lt;P&gt;Please see the example in the link provided. In the end, however, it should look something like this:&lt;/P&gt;

&lt;HR /&gt;

&lt;PRE&gt;&lt;CODE&gt;import sys
import splunk.Intersplunk
import string

results = splunk.Intersplunk.readResults(None, None, True)

for event in results:

    """ data analysis and calculations here """

    ...    

    """ add new field 'newname' """
    event['newname'] = "".join(newval)

splunk.Intersplunk.outputResults(results)
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;HR /&gt;

&lt;P&gt;I hope this helps.&lt;/P&gt;</description>
      <pubDate>Mon, 27 May 2013 19:27:40 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/perl-script/m-p/46377#M11097</guid>
      <dc:creator>Gilberto_Castil</dc:creator>
      <dc:date>2013-05-27T19:27:40Z</dc:date>
    </item>
    <item>
      <title>Re: perl script</title>
      <link>https://community.splunk.com/t5/Splunk-Search/perl-script/m-p/46378#M11098</link>
      <description>&lt;P&gt;Thank you, I will try with python because, with perl, I don't see how I can give my splunk table and how I give the results back.&lt;/P&gt;</description>
      <pubDate>Tue, 28 May 2013 07:58:47 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/perl-script/m-p/46378#M11098</guid>
      <dc:creator>Fabien05</dc:creator>
      <dc:date>2013-05-28T07:58:47Z</dc:date>
    </item>
  </channel>
</rss>

