<?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: Aggr function in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639524#M234439</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Allega il documento e cercherò di darti una mano ....&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 04 Jun 2014 15:24:51 GMT</pubDate>
    <dc:creator>alexandros17</dc:creator>
    <dc:date>2014-06-04T15:24:51Z</dc:date>
    <item>
      <title>Aggr function</title>
      <link>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639523#M234438</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi to all,&lt;/P&gt;&lt;P&gt;I tried everything but I can't resolve this issue,hope someone can help me&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have this pivot table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="image.png" class="jive-image jiveImage" src="https://community.qlik.com/legacyfs/online/60097_image.png" /&gt;&lt;/P&gt;&lt;P&gt;I'll try to explain what I want to do:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL style="list-style-type: disc;"&gt;&lt;LI&gt;If I have Dato = 'HC PROCESS FLARING'&lt;SPAN style="text-decoration: underline;"&gt; in a SITE,&lt;/SPAN&gt; when DATO = 'HC PROCESS FLARING' only Column "hc flaring sm3" must be populated; when DATO = 'PROCESS FLARING' only column Total Flaring sm3, as shown in Figure.&lt;/LI&gt;&lt;LI&gt;If site doesn't have DATO = 'HC PROCESS FLARING' in a SITE I need the same value for both columns.&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope to do this in front end.&lt;/P&gt;&lt;P&gt;I think something with concat and aggrs, but I can't resolve it...any suggestions?&lt;/P&gt;&lt;P&gt;Thanks in advice!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 04 Jun 2014 15:09:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639523#M234438</guid>
      <dc:creator />
      <dc:date>2014-06-04T15:09:59Z</dc:date>
    </item>
    <item>
      <title>Re: Aggr function</title>
      <link>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639524#M234439</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Allega il documento e cercherò di darti una mano ....&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 04 Jun 2014 15:24:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639524#M234439</guid>
      <dc:creator>alexandros17</dc:creator>
      <dc:date>2014-06-04T15:24:51Z</dc:date>
    </item>
    <item>
      <title>Re: Aggr function</title>
      <link>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639525#M234440</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Antonio,&lt;/P&gt;&lt;P&gt;Can you show me your QVW file ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hugs&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 04 Jun 2014 15:40:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639525#M234440</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-06-04T15:40:56Z</dc:date>
    </item>
    <item>
      <title>Re: Aggr function</title>
      <link>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639526#M234441</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi guys, I know it's better but qvw it's 165 Mb, and it's classified &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/sad.png" /&gt;&lt;/P&gt;&lt;P&gt;I hope to solve it in pivot table expressions and not in back end, if it's possible, because script it's terrible and huge(not mine, thanks god &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;).&lt;/P&gt;&lt;P&gt;Thanks for your help!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Antonio&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 04 Jun 2014 15:47:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639526#M234441</guid>
      <dc:creator />
      <dc:date>2014-06-04T15:47:43Z</dc:date>
    </item>
    <item>
      <title>Re: Aggr function</title>
      <link>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639527#M234442</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;A little hint, don't have time at this moment for details...&lt;/P&gt;&lt;P&gt;This expression should return 0 for a SITE&amp;nbsp; that doesn't have 'HC PROCESS FLARING' and &amp;gt;0 for anyhting else:&lt;/P&gt;&lt;P&gt;=index(concat(total&amp;lt;SITE&amp;gt; DATO, '|'), '|HC PROCESS FLARING|')&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 04 Jun 2014 20:59:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639527#M234442</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-06-04T20:59:04Z</dc:date>
    </item>
    <item>
      <title>Re: Aggr function</title>
      <link>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639528#M234443</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try these two expressions.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Total Flaring [Sm3]:&lt;/STRONG&gt; &lt;SPAN style="font-family: 'courier new', courier;"&gt;if(DATO &amp;lt;&amp;gt; 'HC PROCESS FLARING', Sum(Value))&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;HC Flaring [Sm3]:&lt;/STRONG&gt; &lt;SPAN style="font-family: 'courier new', courier;"&gt;if(DATO &amp;lt;&amp;gt; 'PROCESS FLARING', Sum(Value))&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Of course, substitute "&lt;SPAN style="font-family: 'courier new', courier;"&gt;Sum(Value)&lt;/SPAN&gt;" with what you are trying to calculate. If they do not work, please post the dimensions and expressions you are using on that table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 04 Jun 2014 21:19:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639528#M234443</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-06-04T21:19:12Z</dc:date>
    </item>
    <item>
      <title>Re: Aggr function</title>
      <link>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639529#M234444</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Michael, thanks for your trick, i'll try it tomorrow morning and let you know!&lt;/P&gt;&lt;P&gt;Thanks again!!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 04 Jun 2014 21:23:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639529#M234444</guid>
      <dc:creator />
      <dc:date>2014-06-04T21:23:50Z</dc:date>
    </item>
    <item>
      <title>Re: Aggr function</title>
      <link>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639530#M234445</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Bruno, thanks for your reply.&lt;/P&gt;&lt;P&gt;I'm using these two expressions, but this doesn't works in the second half of the pic (green).&lt;/P&gt;&lt;P&gt;Dimensions are Consociata, Site, Gruppo and Dato and two expression are like yours.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks again!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 04 Jun 2014 21:27:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639530#M234445</guid>
      <dc:creator />
      <dc:date>2014-06-04T21:27:22Z</dc:date>
    </item>
    <item>
      <title>Re: Aggr function</title>
      <link>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639531#M234446</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, I had not understood very well what were your requirements. I think I know now. Using Michael's tip, let's try this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Total Flaring [Sm3]:&lt;/STRONG&gt; &lt;SPAN style="font-family: 'courier new', courier;"&gt;If(Index(Concat(Total&amp;lt;SITE&amp;gt; DATO, '|'), 'HC PROCESS FLARING')&lt;SPAN style="font-family: 'courier new', courier;"&gt; &amp;gt; 0,&lt;/SPAN&gt; Sum(if(DATO &amp;lt;&amp;gt; 'HC PROCESS FLARING', Value)), Sum(Value))&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;HC Flaring [Sm3]:&lt;/STRONG&gt; &lt;SPAN style="font-family: 'courier new', courier;"&gt;If(Index(Concat(Total&amp;lt;SITE&amp;gt; DATO, '|'), 'HC PROCESS FLARING')&lt;/SPAN&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt; &amp;gt; 0,&lt;/SPAN&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;Sum(&lt;/SPAN&gt;if(DATO &amp;lt;&amp;gt; 'PROCESS FLARING', Value))&lt;SPAN style="font-family: 'courier new', courier;"&gt;, Sum(Value))&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If it doesn't work, we'll need more information about your data model.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 04 Jun 2014 21:50:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639531#M234446</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-06-04T21:50:43Z</dc:date>
    </item>
    <item>
      <title>Re: Aggr function</title>
      <link>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639532#M234447</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Bruno,&lt;/P&gt;&lt;P&gt;doesn't work..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="immagine.png" class="jive-image" src="https://community.qlik.com/legacyfs/online/60143_immagine.png" /&gt;&lt;/P&gt;&lt;P&gt;The correct behavior is Site "F", in the others Process Flaring should have both columns with the same value.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 05 Jun 2014 07:21:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639532#M234447</guid>
      <dc:creator />
      <dc:date>2014-06-05T07:21:58Z</dc:date>
    </item>
    <item>
      <title>Re: Aggr function</title>
      <link>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639533#M234448</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;That's not the behavior in the yellow part of you first image. Anyway, all you need is to change the second expression to &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;HC Flaring [Sm3]:&lt;/STRONG&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-family: 'courier new', courier; color: #3d3d3d;"&gt;If(Index(Concat(Total&amp;lt;SITE&amp;gt; DATO, '|'), 'HC PROCESS FLARING')&lt;/SPAN&gt;&lt;SPAN style="font-family: 'courier new', courier; color: #3d3d3d;"&gt; &amp;gt; 0,&lt;/SPAN&gt;&lt;SPAN style="font-family: 'courier new', courier; color: #3d3d3d;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #3d3d3d; font-style: inherit; font-family: 'courier new', courier; font-weight: inherit;"&gt;Sum(Value), 0)&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 05 Jun 2014 12:06:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639533#M234448</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-06-05T12:06:45Z</dc:date>
    </item>
    <item>
      <title>Re: Aggr function</title>
      <link>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639534#M234449</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Bruno, thanks again.&lt;/P&gt;&lt;P&gt;Yellow part and green are different (one with HC process Flaring, other no).&lt;/P&gt;&lt;P&gt;Changing the second expression I have both column with the same values in every case, also in Site "F" and it's wrong.&lt;/P&gt;&lt;P&gt;Thanks again for your help!&lt;/P&gt;&lt;P&gt;Antonio&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 05 Jun 2014 12:19:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Aggr-function/m-p/639534#M234449</guid>
      <dc:creator />
      <dc:date>2014-06-05T12:19:45Z</dc:date>
    </item>
  </channel>
</rss>

