<?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: IF then problems... in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/IF-then-problems/m-p/348082#M174883</link>
    <description>&lt;P&gt;Thats so simple, took me ages trying to get that working! many thanks!&lt;/P&gt;</description>
    <pubDate>Mon, 24 Apr 2017 10:33:21 GMT</pubDate>
    <dc:creator>jacqu3sy</dc:creator>
    <dc:date>2017-04-24T10:33:21Z</dc:date>
    <item>
      <title>IF then problems...</title>
      <link>https://community.splunk.com/t5/Splunk-Search/IF-then-problems/m-p/348079#M174880</link>
      <description>&lt;P&gt;struggling with the following IF statement....&lt;/P&gt;

&lt;P&gt;I have a table, and want to create a new field called 'finalclosedtime' which will be populated either by an existing field called 'closedtime' or a string IF one of the other fields contains a value of "New".&lt;/P&gt;

&lt;P&gt;I tried this but no joy:&lt;/P&gt;

&lt;P&gt;| eval finalclosedtime=if((status_label="New",stringtopopulate)closedtime)&lt;/P&gt;

&lt;P&gt;Any ideas? Thanks.&lt;/P&gt;</description>
      <pubDate>Mon, 24 Apr 2017 10:12:23 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/IF-then-problems/m-p/348079#M174880</guid>
      <dc:creator>jacqu3sy</dc:creator>
      <dc:date>2017-04-24T10:12:23Z</dc:date>
    </item>
    <item>
      <title>Re: IF then problems...</title>
      <link>https://community.splunk.com/t5/Splunk-Search/IF-then-problems/m-p/348080#M174881</link>
      <description>&lt;P&gt;You can form the field this way -&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| eval finalclosedtime=if(like(status_label,"%New%"),stringtopopulate,closedtime)
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 24 Apr 2017 10:19:02 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/IF-then-problems/m-p/348080#M174881</guid>
      <dc:creator>dineshraj9</dc:creator>
      <dc:date>2017-04-24T10:19:02Z</dc:date>
    </item>
    <item>
      <title>Re: IF then problems...</title>
      <link>https://community.splunk.com/t5/Splunk-Search/IF-then-problems/m-p/348081#M174882</link>
      <description>&lt;P&gt;Hi There, try it simply as:&lt;/P&gt;

&lt;P&gt;| eval finalclosedtime=if(status_label="New", stringtopopulate, closedtime)&lt;/P&gt;</description>
      <pubDate>Mon, 24 Apr 2017 10:22:28 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/IF-then-problems/m-p/348081#M174882</guid>
      <dc:creator>paulbannister</dc:creator>
      <dc:date>2017-04-24T10:22:28Z</dc:date>
    </item>
    <item>
      <title>Re: IF then problems...</title>
      <link>https://community.splunk.com/t5/Splunk-Search/IF-then-problems/m-p/348082#M174883</link>
      <description>&lt;P&gt;Thats so simple, took me ages trying to get that working! many thanks!&lt;/P&gt;</description>
      <pubDate>Mon, 24 Apr 2017 10:33:21 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/IF-then-problems/m-p/348082#M174883</guid>
      <dc:creator>jacqu3sy</dc:creator>
      <dc:date>2017-04-24T10:33:21Z</dc:date>
    </item>
    <item>
      <title>Re: IF then problems...</title>
      <link>https://community.splunk.com/t5/Splunk-Search/IF-then-problems/m-p/348083#M174884</link>
      <description>&lt;P&gt;no problem &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 24 Apr 2017 10:35:19 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/IF-then-problems/m-p/348083#M174884</guid>
      <dc:creator>dineshraj9</dc:creator>
      <dc:date>2017-04-24T10:35:19Z</dc:date>
    </item>
    <item>
      <title>Re: IF then problems...</title>
      <link>https://community.splunk.com/t5/Splunk-Search/IF-then-problems/m-p/348084#M174885</link>
      <description>&lt;P&gt;Also worked, thanks!&lt;/P&gt;</description>
      <pubDate>Mon, 24 Apr 2017 12:45:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/IF-then-problems/m-p/348084#M174885</guid>
      <dc:creator>jacqu3sy</dc:creator>
      <dc:date>2017-04-24T12:45:24Z</dc:date>
    </item>
    <item>
      <title>Re: IF then problems...</title>
      <link>https://community.splunk.com/t5/Splunk-Search/IF-then-problems/m-p/348085#M174886</link>
      <description>&lt;P&gt;Great!  Please accept the answer that solved the problem, and upvote any other answers that you found particularly helpful.&lt;/P&gt;</description>
      <pubDate>Mon, 24 Apr 2017 15:41:12 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/IF-then-problems/m-p/348085#M174886</guid>
      <dc:creator>DalJeanis</dc:creator>
      <dc:date>2017-04-24T15:41:12Z</dc:date>
    </item>
  </channel>
</rss>

