<?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: Eval statement based of 1 field using If in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Eval-statement-based-of-1-field-using-If/m-p/508876#M142169</link>
    <description>&lt;P&gt;Perhaps this will help&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;... | eval Capacity = if(vendor="foo" OR vendor="bar", exact((GB*1.1)/1024)*0.909495), GB)&lt;/LI-CODE&gt;</description>
    <pubDate>Mon, 13 Jul 2020 18:54:26 GMT</pubDate>
    <dc:creator>richgalloway</dc:creator>
    <dc:date>2020-07-13T18:54:26Z</dc:date>
    <item>
      <title>Eval statement based of 1 field using If</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Eval-statement-based-of-1-field-using-If/m-p/508836#M142158</link>
      <description>&lt;P&gt;I have a bunch of storage clusters that we monitor,&amp;nbsp; 60% of the envrioment uses normal GB, the other 40% uses GiB.&amp;nbsp; I need to show all of the storage arrays in 1 report and normalize the storage to GB, and the only field that is different between the storage besides the array name is "storage vendor" .&amp;nbsp; I need to create an If statement if vendor is like "X"&amp;nbsp; run these evals&amp;nbsp;&lt;BR /&gt;|eval _GB_TiB = (((Capacity_GB)*1.1)/1024)*0.909495&lt;BR /&gt;| eval "Prov(TiB)" = (((prov_GB)*1.1)/1024)*0.909495&lt;BR /&gt;| eval "Written(TiB)" = ((((writtedGB)*1.1)/1024)*0.909495)/2&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 13 Jul 2020 16:05:18 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Eval-statement-based-of-1-field-using-If/m-p/508836#M142158</guid>
      <dc:creator>codedtech</dc:creator>
      <dc:date>2020-07-13T16:05:18Z</dc:date>
    </item>
    <item>
      <title>Re: Eval statement based of 1 field using If</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Eval-statement-based-of-1-field-using-If/m-p/508839#M142159</link>
      <description>How should Splunk distinguish those that use GB from those that use GiB?</description>
      <pubDate>Mon, 13 Jul 2020 16:04:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Eval-statement-based-of-1-field-using-If/m-p/508839#M142159</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2020-07-13T16:04:07Z</dc:date>
    </item>
    <item>
      <title>Re: Eval statement based of 1 field using If</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Eval-statement-based-of-1-field-using-If/m-p/508852#M142163</link>
      <description>&lt;P&gt;I like to use an If or case statement ideally based of the vendor or storage array name.&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;something along the lines like this&lt;/P&gt;&lt;P&gt;query|eval if(vendor="vendor 1(then&amp;nbsp; eval Capacity(TiB) = (((Capacity_GB)*1.1)/1024)*0.909495&lt;BR /&gt;| eval "provisioned (TiB)" = (((provisionedGB)*1.1)/1024)*0.909495&lt;BR /&gt;| eval "Written(TiB)" = ((((usedGB)*1.1)/1024)*0.909495)/2&lt;/P&gt;</description>
      <pubDate>Mon, 13 Jul 2020 16:50:06 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Eval-statement-based-of-1-field-using-If/m-p/508852#M142163</guid>
      <dc:creator>codedtech</dc:creator>
      <dc:date>2020-07-13T16:50:06Z</dc:date>
    </item>
    <item>
      <title>Re: Eval statement based of 1 field using If</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Eval-statement-based-of-1-field-using-If/m-p/508876#M142169</link>
      <description>&lt;P&gt;Perhaps this will help&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;... | eval Capacity = if(vendor="foo" OR vendor="bar", exact((GB*1.1)/1024)*0.909495), GB)&lt;/LI-CODE&gt;</description>
      <pubDate>Mon, 13 Jul 2020 18:54:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Eval-statement-based-of-1-field-using-If/m-p/508876#M142169</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2020-07-13T18:54:26Z</dc:date>
    </item>
  </channel>
</rss>

