<?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: Total Dead Inventory On Hand using Sum If  with AGGR in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Total-Dead-Inventory-On-Hand-using-Sum-If-with-AGGR/m-p/910819#M316251</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please try below&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;aggr(sum({&amp;lt;Date = {"&amp;gt;=$(=addmonths(Today(),-36))"}&amp;gt;},OnHandValue)/sum({&amp;lt;Date = {"&amp;gt;=$(=addmonths(Today(),-36))"}&amp;gt;}CostofGoodsSold),MaterialID)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;or&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;aggr(sum({&amp;lt;Date = {"&amp;gt;=$(=addmonths(Today(),-36))"}&amp;gt;},&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;QuantityOnHand*PurchasePrice&lt;/SPAN&gt;)/sum({&amp;lt;Date = {"&amp;gt;=$(=addmonths(Today(),-36))"}&amp;gt;}CostofGoodsSold),MaterialID) &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 04 Aug 2015 20:21:38 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2015-08-04T20:21:38Z</dc:date>
    <item>
      <title>Total Dead Inventory On Hand using Sum If  with AGGR</title>
      <link>https://community.qlik.com/t5/QlikView/Total-Dead-Inventory-On-Hand-using-Sum-If-with-AGGR/m-p/910817#M316249</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi everyone,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm trying to add up inventory values for set of materials that are classified as dead inventory on hand. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;First, I created an AGGR function to determine what is classified as dead inventory.(Months of Inventory On Hand &amp;gt; 36 months)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;AGGR(OnHandValue/CostofGoodsSold,MaterialID)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So I want to capture the On Hand Value for all materials that has&amp;nbsp; &amp;gt; 36 months&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I was hoping that following would do the trick but I can't seem to make it work:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=sum(if(AGGR(OnHandValue/CostofGoodsSold,MaterialID)&amp;gt;36,OnHandValue),0)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any ideas please? I tried a second AGGR for OnHandValue to be summed but that didn't do anything either. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance for taking a look.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Aug 2015 19:57:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Total-Dead-Inventory-On-Hand-using-Sum-If-with-AGGR/m-p/910817#M316249</guid>
      <dc:creator />
      <dc:date>2015-08-04T19:57:25Z</dc:date>
    </item>
    <item>
      <title>Re: Total Dead Inventory On Hand using Sum If  with AGGR</title>
      <link>https://community.qlik.com/t5/QlikView/Total-Dead-Inventory-On-Hand-using-Sum-If-with-AGGR/m-p/910818#M316250</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I forgot to mention that OnHandValue is also a function like&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sum(QuantityOnHand*PurchasePrice)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So maybe that's what's causing the problem. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Aug 2015 19:59:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Total-Dead-Inventory-On-Hand-using-Sum-If-with-AGGR/m-p/910818#M316250</guid>
      <dc:creator />
      <dc:date>2015-08-04T19:59:17Z</dc:date>
    </item>
    <item>
      <title>Re: Total Dead Inventory On Hand using Sum If  with AGGR</title>
      <link>https://community.qlik.com/t5/QlikView/Total-Dead-Inventory-On-Hand-using-Sum-If-with-AGGR/m-p/910819#M316251</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please try below&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;aggr(sum({&amp;lt;Date = {"&amp;gt;=$(=addmonths(Today(),-36))"}&amp;gt;},OnHandValue)/sum({&amp;lt;Date = {"&amp;gt;=$(=addmonths(Today(),-36))"}&amp;gt;}CostofGoodsSold),MaterialID)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;or&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;aggr(sum({&amp;lt;Date = {"&amp;gt;=$(=addmonths(Today(),-36))"}&amp;gt;},&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;QuantityOnHand*PurchasePrice&lt;/SPAN&gt;)/sum({&amp;lt;Date = {"&amp;gt;=$(=addmonths(Today(),-36))"}&amp;gt;}CostofGoodsSold),MaterialID) &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Aug 2015 20:21:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Total-Dead-Inventory-On-Hand-using-Sum-If-with-AGGR/m-p/910819#M316251</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-08-04T20:21:38Z</dc:date>
    </item>
  </channel>
</rss>

