<?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. :Re: AGGR in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/AGGR/m-p/205507#M1209323</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi JJ,&lt;/P&gt;&lt;P&gt;I am waiting for your reply. Requirement is very urgent please help me out.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rikab&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 25 Jan 2010 11:30:36 GMT</pubDate>
    <dc:creator />
    <dc:date>2010-01-25T11:30:36Z</dc:date>
    <item>
      <title>AGGR</title>
      <link>https://community.qlik.com/t5/QlikView/AGGR/m-p/205498#M1209314</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;I have some difficulies to understand well the AGGR( ) function, which is very useful as I saw in the forum&lt;/P&gt;&lt;P&gt;Is anybody can give me some example to be more confortable with or some argument.&lt;/P&gt;&lt;P&gt;Thanks again for your time.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Jean-Jacques&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Nov 2009 04:17:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/AGGR/m-p/205498#M1209314</guid>
      <dc:creator />
      <dc:date>2009-11-27T04:17:30Z</dc:date>
    </item>
    <item>
      <title>AGGR</title>
      <link>https://community.qlik.com/t5/QlikView/AGGR/m-p/205499#M1209315</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Jean-Jacques,&lt;BR /&gt;There could be many very different situation. Only one example:&lt;BR /&gt;There are two tables:&lt;BR /&gt;&lt;/P&gt;&lt;BLOCKQUOTE style="overflow-x: scroll;"&gt;&lt;PRE style="margin: 0px;"&gt;&lt;BR /&gt;Master:&lt;BR /&gt; SalesId,&lt;BR /&gt; SalesDate,&lt;BR /&gt; Amount,&lt;BR /&gt; ...&lt;BR /&gt;FROM...;&lt;BR /&gt;Details:&lt;BR /&gt; SalesId,&lt;BR /&gt; Product,&lt;BR /&gt; ...&lt;BR /&gt;FROM ...;&lt;BR /&gt;&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;You can see that the relation is one (Master record) to many (Details records). You certainly can join into one table, but it will mutliply the number of records. &lt;BR /&gt;In case you don't have to join them, the expression sum(Amount) will work fine. But if for any reason you have to join, the result will be incorrect. It can be corrected by using sum(aggr(only(Amount), SalesId)). No matte rhow many times the same SalesId appear in the table, it's Amoun twill be used only once in the sum(). &lt;BR /&gt;Apparently the example is not typical, just for illustration. &lt;BR /&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Nov 2009 05:26:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/AGGR/m-p/205499#M1209315</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2009-11-27T05:26:59Z</dc:date>
    </item>
    <item>
      <title>Re. :Re: AGGR</title>
      <link>https://community.qlik.com/t5/QlikView/AGGR/m-p/205500#M1209316</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yep ! i understand why i don't have the need to use AGGR, it's because i never joined table.&lt;/P&gt;&lt;P&gt;Thanks Michael.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;JJ&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Nov 2009 15:45:19 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/AGGR/m-p/205500#M1209316</guid>
      <dc:creator />
      <dc:date>2009-11-27T15:45:19Z</dc:date>
    </item>
    <item>
      <title>AGGR</title>
      <link>https://community.qlik.com/t5/QlikView/AGGR/m-p/205501#M1209317</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;So what about if you did not join the tables and you want to plot the average amount of Detail records per Master record. (E.g. Average Products per SalesId.) Would the expression be "avg(aggr(count(Product), SalesId))" or what would that give me?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;/Niclas&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 01 Dec 2009 15:59:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/AGGR/m-p/205501#M1209317</guid>
      <dc:creator />
      <dc:date>2009-12-01T15:59:03Z</dc:date>
    </item>
    <item>
      <title>AGGR</title>
      <link>https://community.qlik.com/t5/QlikView/AGGR/m-p/205502#M1209318</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I use aggr function when i have to simulate where clause in a graph.&lt;/P&gt;&lt;P&gt;For example: Display a graph with articles more than 5 of quantity.&lt;/P&gt;&lt;P&gt;You have to perform an expression ( for example sum(ITEM_QTY) ) and decide if your article should taken or not. Tha aggr function let you to bring this decision.&lt;/P&gt;&lt;P&gt;In the graph you have also to check that you don't want to display null value dimensions.&lt;/P&gt;&lt;P&gt;See this example&lt;/P&gt;&lt;P&gt;Hope this help&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Wink" src="http://community.qlik.com/emoticons/emotion-5.gif" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 01 Dec 2009 16:57:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/AGGR/m-p/205502#M1209318</guid>
      <dc:creator />
      <dc:date>2009-12-01T16:57:38Z</dc:date>
    </item>
    <item>
      <title>Re. :Re: AGGR</title>
      <link>https://community.qlik.com/t5/QlikView/AGGR/m-p/205503#M1209319</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;nice example Bud !&lt;/P&gt;&lt;P&gt;it's better than to create a flag as i did.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;JJ&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Dec 2009 02:59:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/AGGR/m-p/205503#M1209319</guid>
      <dc:creator />
      <dc:date>2009-12-02T02:59:33Z</dc:date>
    </item>
    <item>
      <title>Re. :Re: AGGR</title>
      <link>https://community.qlik.com/t5/QlikView/AGGR/m-p/205504#M1209320</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Bud,&lt;/P&gt;&lt;P&gt;I am also facing problem in understanding about aggr. Can you please explain me how the below code behaves as i don't have any clue on how it works. For your reference i have attached the same document which i downloaded for understanding about aggr. Hope you can provide me the solution.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE style="overflow-x: scroll;"&gt;&lt;PRE style="margin: 0px;"&gt;count(if(aggr(sum(sales), year, company)&amp;gt;iDiffValue,1))&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 17 Jan 2010 08:25:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/AGGR/m-p/205504#M1209320</guid>
      <dc:creator />
      <dc:date>2010-01-17T08:25:26Z</dc:date>
    </item>
    <item>
      <title>Re. :Re: AGGR</title>
      <link>https://community.qlik.com/t5/QlikView/AGGR/m-p/205505#M1209321</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Now I think AGGR is the best function in QV. With this, you don't need to aggregate the data outside of QV.&lt;/P&gt;&lt;P&gt;In the example you mentionned you have 3 steps ;:&lt;/P&gt;&lt;P&gt;1) for each year and for each company, you sum the sales =&amp;gt; A&lt;/P&gt;&lt;P&gt;2) if A &amp;gt; &lt;EM&gt;threshold&lt;/EM&gt; , you count 1 =&amp;gt; B&lt;/P&gt;&lt;P&gt;3) a after you count the number of B&lt;/P&gt;&lt;P&gt;Hope to help you.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Look at this example with 2 AGGR !&lt;/P&gt;&lt;P&gt;= Sum( Aggr( Max( aggr( sum(Close_Hour-Open_Hour)*24 , pcbur , Period) ) , pcbur) )&lt;/P&gt;&lt;P&gt;I just want to calculate the how many hours all the stores (pcbur) of an area (my dimension) are open by week.&lt;/P&gt;&lt;P&gt;regards.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;jj&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 18 Jan 2010 18:40:13 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/AGGR/m-p/205505#M1209321</guid>
      <dc:creator />
      <dc:date>2010-01-18T18:40:13Z</dc:date>
    </item>
    <item>
      <title>Re. :Re: AGGR</title>
      <link>https://community.qlik.com/t5/QlikView/AGGR/m-p/205506#M1209322</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi JJ,&lt;/P&gt;&lt;P&gt;I am totally confused here. Still i am not able to understand anything :-(. Could you please work it on in my document so that it is understandable for me. Also requesting you to explain it with some sample data also.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 22 Jan 2010 08:36:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/AGGR/m-p/205506#M1209322</guid>
      <dc:creator />
      <dc:date>2010-01-22T08:36:56Z</dc:date>
    </item>
    <item>
      <title>Re. :Re: AGGR</title>
      <link>https://community.qlik.com/t5/QlikView/AGGR/m-p/205507#M1209323</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi JJ,&lt;/P&gt;&lt;P&gt;I am waiting for your reply. Requirement is very urgent please help me out.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rikab&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 25 Jan 2010 11:30:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/AGGR/m-p/205507#M1209323</guid>
      <dc:creator />
      <dc:date>2010-01-25T11:30:36Z</dc:date>
    </item>
    <item>
      <title>Re. :Re: AGGR</title>
      <link>https://community.qlik.com/t5/QlikView/AGGR/m-p/205508#M1209324</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Rikak&lt;/P&gt;&lt;P&gt;I don't understand what you don't understand in the formula&lt;/P&gt;&lt;PRE style="margin:0px;"&gt;count(if(aggr(sum(sales), year, company)&amp;gt;iDiffValue,1))&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Let's try step by step,&lt;BR /&gt;&lt;BR /&gt;First, you want a chart with year as dimension&lt;BR /&gt;Second, you want to count hom many company each year has a sum of sale &amp;gt; IdiffValue (it's your threshold).&lt;BR /&gt;To do this directly in the chart, you calculate &lt;B&gt;aggr(sum(sales), year, company)&lt;/B&gt;&lt;BR /&gt; =&amp;gt; it's the calculation by year &amp;amp; by company of the sales&lt;BR /&gt;&lt;BR /&gt;Then you have to create a flag (1 or 0)&lt;BR /&gt; as if( &lt;B&gt;aggr(sum(sales), year, company)&lt;/B&gt; &amp;gt; iDiffValue, 1 ) = 1 if &lt;B&gt;aggr(sum(sales), year, company)&lt;/B&gt; &amp;gt; iDiffValue&lt;BR /&gt; = Missing otherwise&lt;BR /&gt;&lt;BR /&gt;Then you count the number of "1" . The count function deals with your dimension, the year in your case.&lt;BR /&gt;&lt;BR /&gt;Hope to help you&lt;BR /&gt;&lt;BR /&gt;JJ&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 25 Jan 2010 17:31:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/AGGR/m-p/205508#M1209324</guid>
      <dc:creator />
      <dc:date>2010-01-25T17:31:50Z</dc:date>
    </item>
  </channel>
</rss>

