<?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 concatenate a string with a value containing special characters? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-concatenate-a-string-with-a-value-containing-special/m-p/134835#M36843</link>
    <description>&lt;P&gt;Can you paste what the output of the below code looks like?&lt;BR /&gt;
I did a quick test of the code above and it seems to work fine &lt;/P&gt;

&lt;P&gt;index=myindex   | table Account&lt;/P&gt;</description>
    <pubDate>Tue, 10 Feb 2015 23:21:05 GMT</pubDate>
    <dc:creator>ramdaspr</dc:creator>
    <dc:date>2015-02-10T23:21:05Z</dc:date>
    <item>
      <title>How to concatenate a string with a value containing special characters?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-concatenate-a-string-with-a-value-containing-special/m-p/134829#M36837</link>
      <description>&lt;P&gt;Hello Everyone,&lt;/P&gt;

&lt;P&gt;I have a file containing &lt;CODE&gt;Account ="xxx/\xxx/\xxx/\xx"&lt;/CODE&gt; value and this needs to be concatenated with a string, say "my account"  .&lt;/P&gt;

&lt;P&gt;when i tried following search:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=myindex  | eval description= "my account" + Account | table description
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;getting blank for "description" .&lt;/P&gt;

&lt;P&gt;Can any one guide me where aI'm going wrong ??? or this is because of the "/\" character in the string?&lt;/P&gt;

&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Tue, 10 Feb 2015 15:30:39 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-concatenate-a-string-with-a-value-containing-special/m-p/134829#M36837</guid>
      <dc:creator>snehal8</dc:creator>
      <dc:date>2015-02-10T15:30:39Z</dc:date>
    </item>
    <item>
      <title>Re: How to concatenate a string with a value containing special characters?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-concatenate-a-string-with-a-value-containing-special/m-p/134830#M36838</link>
      <description>&lt;P&gt;use .&lt;/P&gt;

&lt;P&gt;index=myindex  | eval description= "my account".Account | table description&lt;/P&gt;</description>
      <pubDate>Tue, 10 Feb 2015 15:53:38 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-concatenate-a-string-with-a-value-containing-special/m-p/134830#M36838</guid>
      <dc:creator>mzorzi</dc:creator>
      <dc:date>2015-02-10T15:53:38Z</dc:date>
    </item>
    <item>
      <title>Re: How to concatenate a string with a value containing special characters?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-concatenate-a-string-with-a-value-containing-special/m-p/134831#M36839</link>
      <description>&lt;P&gt;I don't think the characters will matter.&lt;/P&gt;

&lt;P&gt;To prove this, try replacing them with something else?&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=myindex | eval rfield=REPLACE(Account, "/", "-") | eval description="my account" + rfield | table description
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 10 Feb 2015 15:57:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-concatenate-a-string-with-a-value-containing-special/m-p/134831#M36839</guid>
      <dc:creator>kendrickt</dc:creator>
      <dc:date>2015-02-10T15:57:26Z</dc:date>
    </item>
    <item>
      <title>Re: How to concatenate a string with a value containing special characters?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-concatenate-a-string-with-a-value-containing-special/m-p/134832#M36840</link>
      <description>&lt;P&gt;Thanks for reply @mzorzi. but it is not working. &lt;/P&gt;</description>
      <pubDate>Tue, 10 Feb 2015 16:00:00 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-concatenate-a-string-with-a-value-containing-special/m-p/134832#M36840</guid>
      <dc:creator>snehal8</dc:creator>
      <dc:date>2015-02-10T16:00:00Z</dc:date>
    </item>
    <item>
      <title>Re: How to concatenate a string with a value containing special characters?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-concatenate-a-string-with-a-value-containing-special/m-p/134833#M36841</link>
      <description>&lt;P&gt;Thanks for reply @kendrickt.. same not getting display !!!&lt;/P&gt;</description>
      <pubDate>Tue, 10 Feb 2015 16:31:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-concatenate-a-string-with-a-value-containing-special/m-p/134833#M36841</guid>
      <dc:creator>snehal8</dc:creator>
      <dc:date>2015-02-10T16:31:01Z</dc:date>
    </item>
    <item>
      <title>Re: How to concatenate a string with a value containing special characters?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-concatenate-a-string-with-a-value-containing-special/m-p/134834#M36842</link>
      <description>&lt;P&gt;Do the quote characters show up in the Account field? If so I wonder if that is throwing it off. Maybe try the following before your eval &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;... | rex field=Account "\"(?&amp;lt;Account&amp;gt;[^\"]+)" | ...
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 10 Feb 2015 21:41:38 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-concatenate-a-string-with-a-value-containing-special/m-p/134834#M36842</guid>
      <dc:creator>Runals</dc:creator>
      <dc:date>2015-02-10T21:41:38Z</dc:date>
    </item>
    <item>
      <title>Re: How to concatenate a string with a value containing special characters?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-concatenate-a-string-with-a-value-containing-special/m-p/134835#M36843</link>
      <description>&lt;P&gt;Can you paste what the output of the below code looks like?&lt;BR /&gt;
I did a quick test of the code above and it seems to work fine &lt;/P&gt;

&lt;P&gt;index=myindex   | table Account&lt;/P&gt;</description>
      <pubDate>Tue, 10 Feb 2015 23:21:05 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-concatenate-a-string-with-a-value-containing-special/m-p/134835#M36843</guid>
      <dc:creator>ramdaspr</dc:creator>
      <dc:date>2015-02-10T23:21:05Z</dc:date>
    </item>
    <item>
      <title>Re: How to concatenate a string with a value containing special characters?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-concatenate-a-string-with-a-value-containing-special/m-p/134836#M36844</link>
      <description>&lt;P&gt;Thanks for reply @ramdaspr. the problem was this string it contain line break, so it was not coming. i used "mvjoin" command for removing line. that it worked !!! &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt; &lt;/P&gt;</description>
      <pubDate>Wed, 11 Feb 2015 14:10:47 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-concatenate-a-string-with-a-value-containing-special/m-p/134836#M36844</guid>
      <dc:creator>snehal8</dc:creator>
      <dc:date>2015-02-11T14:10:47Z</dc:date>
    </item>
    <item>
      <title>Re: How to concatenate a string with a value containing special characters?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-concatenate-a-string-with-a-value-containing-special/m-p/134837#M36845</link>
      <description>&lt;P&gt;Hello All,&lt;/P&gt;

&lt;P&gt;Thanks for your reply, the problem was Account string contain the two values with line break. so i used &lt;CODE&gt;mvjoin&lt;/CODE&gt; command to remove line and now it is working perfectly fine.&lt;/P&gt;

&lt;P&gt;Once again thanks all !! &lt;/P&gt;</description>
      <pubDate>Wed, 11 Feb 2015 14:13:30 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-concatenate-a-string-with-a-value-containing-special/m-p/134837#M36845</guid>
      <dc:creator>snehal8</dc:creator>
      <dc:date>2015-02-11T14:13:30Z</dc:date>
    </item>
  </channel>
</rss>

