<?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 Use subtotal in an expression in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Use-subtotal-in-an-expression/m-p/144031#M23101</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Jsn&lt;/P&gt;&lt;P&gt;Thanks for the very prompt response, much appreciated.&lt;/P&gt;&lt;P&gt;I tried that and it works fine for levels 2 and 3, but doesn't work on level 1. If I put the statement in as anexpression (i.e. aggr(sum(x),Dim1) then what I get is a blank value at the first line and a value of 4 on the second line. It would appear that the expression to change colour is probably referencing the first line.&lt;/P&gt;&lt;P&gt;My question is though, why would the result of this expression by any different for any row within the same group? That seems a little bit weird to me?&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Nigel.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 13 May 2009 23:52:27 GMT</pubDate>
    <dc:creator />
    <dc:date>2009-05-13T23:52:27Z</dc:date>
    <item>
      <title>Use subtotal in an expression</title>
      <link>https://community.qlik.com/t5/QlikView/Use-subtotal-in-an-expression/m-p/144029#M23099</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Folks&lt;/P&gt;&lt;P&gt;I have a pivot table which has 4 hierarchial levels and a single value.&lt;/P&gt;&lt;P&gt;I would like at level 1 to change the colour of the text if the sum of all values for that level is N, and of course I'd like to do the same for level 2 &amp;amp; 3, whereas level 4 is the lowest level and so simply doing IF(SUM(X)&amp;lt;&amp;gt;0,RED()) works perfectly.&lt;/P&gt;&lt;P&gt;Anybody know how I can use the value of the partial sum in an expression?&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Nigel.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 13 May 2009 22:17:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Use-subtotal-in-an-expression/m-p/144029#M23099</guid>
      <dc:creator />
      <dc:date>2009-05-13T22:17:43Z</dc:date>
    </item>
    <item>
      <title>Use subtotal in an expression</title>
      <link>https://community.qlik.com/t5/QlikView/Use-subtotal-in-an-expression/m-p/144030#M23100</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Nigel,&lt;/P&gt;&lt;P&gt;I think you should be able to use aggr() here, for example on level 3:&lt;/P&gt;&lt;P&gt;IF(aggr(sum(X), Dim1, Dim2, Dim3)&amp;lt;&amp;gt;0,RED())&lt;/P&gt;&lt;P&gt;If you aggregate the sum over the current dimension level you're on it should color the pivot dimension accordingly&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 13 May 2009 23:00:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Use-subtotal-in-an-expression/m-p/144030#M23100</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2009-05-13T23:00:53Z</dc:date>
    </item>
    <item>
      <title>Use subtotal in an expression</title>
      <link>https://community.qlik.com/t5/QlikView/Use-subtotal-in-an-expression/m-p/144031#M23101</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Jsn&lt;/P&gt;&lt;P&gt;Thanks for the very prompt response, much appreciated.&lt;/P&gt;&lt;P&gt;I tried that and it works fine for levels 2 and 3, but doesn't work on level 1. If I put the statement in as anexpression (i.e. aggr(sum(x),Dim1) then what I get is a blank value at the first line and a value of 4 on the second line. It would appear that the expression to change colour is probably referencing the first line.&lt;/P&gt;&lt;P&gt;My question is though, why would the result of this expression by any different for any row within the same group? That seems a little bit weird to me?&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Nigel.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 13 May 2009 23:52:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Use-subtotal-in-an-expression/m-p/144031#M23101</guid>
      <dc:creator />
      <dc:date>2009-05-13T23:52:27Z</dc:date>
    </item>
  </channel>
</rss>

