<?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: Syntax issues on getting total for a line in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Syntax-issues-on-getting-total-for-a-line/m-p/1000160#M340060</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Camile! Must remember for next time..!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 24 Sep 2015 07:59:04 GMT</pubDate>
    <dc:creator>Dayna</dc:creator>
    <dc:date>2015-09-24T07:59:04Z</dc:date>
    <item>
      <title>Syntax issues on getting total for a line</title>
      <link>https://community.qlik.com/t5/QlikView/Syntax-issues-on-getting-total-for-a-line/m-p/1000155#M340055</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I've attached my application that I'm having issues with, I want to perform a percent calculation that uses the first expression (Volume) and divide by the total volume - which is the value I currently have as a calculated dimension.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, syntax is getting the better of me and I'm struggling to get the same value to apply across all the 'band names' (the dimension used in the pivot table at the top). &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm hoping someone can help me, an example would be the first row; cust code = YVBFU105, the total volume is 1,958.40 and I'd like that value to be displayed for each band name in my second expression. Then what I'll do is divide the value from the band name by the total volume (1,958.40) to give me my percentage. But my expression only seems to put the total in one of the band name values - not all of them.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Your help is always greatly appreciated!! Many thanks in advance.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kind Regards,&lt;/P&gt;&lt;P&gt;Dayna&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 Sep 2015 10:14:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Syntax-issues-on-getting-total-for-a-line/m-p/1000155#M340055</guid>
      <dc:creator>Dayna</dc:creator>
      <dc:date>2015-09-22T10:14:12Z</dc:date>
    </item>
    <item>
      <title>Re: Syntax issues on getting total for a line</title>
      <link>https://community.qlik.com/t5/QlikView/Syntax-issues-on-getting-total-for-a-line/m-p/1000156#M340056</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=num(sum(Aggr(sum(aggr(sum({$&amp;lt;[AR - BandName] = {'Current'}&amp;gt;}[AR - total]/[AR - Ex Rate]),[AR - Cust Bill])),[AR - BandName]))&lt;/P&gt;&lt;P&gt;+&lt;/P&gt;&lt;P&gt;sum(aggr(aggr(sum({$&amp;lt;[AR - BandName] = {'1-30 Days', '31-60 Days', '61-90 Days', '91 Days - Year', 'Year +'} &amp;gt;} [AR - total]/[AR - Ex Rate]),[AR - Cust Bill])&lt;/P&gt;&lt;P&gt;,[AR - BandName]))&lt;/P&gt;&lt;P&gt;,'#,##0.00')&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 Sep 2015 10:53:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Syntax-issues-on-getting-total-for-a-line/m-p/1000156#M340056</guid>
      <dc:creator>sasiparupudi1</dc:creator>
      <dc:date>2015-09-22T10:53:11Z</dc:date>
    </item>
    <item>
      <title>Re: Syntax issues on getting total for a line</title>
      <link>https://community.qlik.com/t5/QlikView/Syntax-issues-on-getting-total-for-a-line/m-p/1000157#M340057</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Dayna,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try using the "NODISTINCT" qualifier for your aggr function as shown below;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="image9.png" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/99699_image9.png" style="height: 166px; width: 620px;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I believe that get's you your desired result.&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Image8.png" class="jive-image image-2" src="https://community.qlik.com/legacyfs/online/99700_Image8.png" style="height: 70px; width: 620px;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Let me know if that helps!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Camile&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 Sep 2015 17:18:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Syntax-issues-on-getting-total-for-a-line/m-p/1000157#M340057</guid>
      <dc:creator>cjohnson</dc:creator>
      <dc:date>2015-09-22T17:18:29Z</dc:date>
    </item>
    <item>
      <title>Re: Syntax issues on getting total for a line</title>
      <link>https://community.qlik.com/t5/QlikView/Syntax-issues-on-getting-total-for-a-line/m-p/1000158#M340058</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Camile,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;That's perfect, thank you! How does the NODISTINCT work in this example? Is it something on the lines of that the aggregation function will ignore the different values (i.e. band name) that it would normally be segregated by?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kind Regards,&lt;/P&gt;&lt;P&gt;Dayna&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Sep 2015 07:52:24 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Syntax-issues-on-getting-total-for-a-line/m-p/1000158#M340058</guid>
      <dc:creator>Dayna</dc:creator>
      <dc:date>2015-09-23T07:52:24Z</dc:date>
    </item>
    <item>
      <title>Re: Syntax issues on getting total for a line</title>
      <link>https://community.qlik.com/t5/QlikView/Syntax-issues-on-getting-total-for-a-line/m-p/1000159#M340059</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;If omitted, By default the aggr function uses DISTINCT as its qualifier. If we look at the definition of the aggr function we see the following:&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px; font-size: 13.3333px;"&gt;aggr ( [distinct | nodistinct ] [set_expression] expression {, dimension} )&lt;/P&gt;&lt;P style="padding-left: 30px; font-size: 13.3333px;"&gt;&lt;EM&gt;If the expression argument is preceded by the nodistinct qualifier,&lt;/EM&gt;&lt;/P&gt;&lt;P style="padding-left: 30px; font-size: 13.3333px;"&gt;&lt;EM&gt;each combination of dimension values may generate more than one&lt;/EM&gt;&lt;/P&gt;&lt;P style="padding-left: 30px; font-size: 13.3333px;"&gt;&lt;EM&gt;return value, depending on underlying data structure. If the expression&lt;/EM&gt;&lt;/P&gt;&lt;P style="padding-left: 30px; font-size: 13.3333px;"&gt;&lt;EM&gt;argument is preceded by the distinct qualifier or if no qualifier&lt;/EM&gt;&lt;/P&gt;&lt;P style="padding-left: 30px; font-size: 13.3333px;"&gt;&lt;EM&gt;is used at all, each combination of dimension values will generate&lt;/EM&gt;&lt;/P&gt;&lt;P style="padding-left: 30px; font-size: 13.3333px;"&gt;&lt;EM&gt;only one return value.&lt;/EM&gt;&lt;/P&gt;&lt;P style="padding-left: 30px; font-size: 13.3333px;"&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;In your application that is exactly what is occurring - the NODISTINCT qualifier allows you to generate more than one return value (only one was being returned before because the qualifier was omitted. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Sep 2015 18:07:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Syntax-issues-on-getting-total-for-a-line/m-p/1000159#M340059</guid>
      <dc:creator>cjohnson</dc:creator>
      <dc:date>2015-09-23T18:07:10Z</dc:date>
    </item>
    <item>
      <title>Re: Syntax issues on getting total for a line</title>
      <link>https://community.qlik.com/t5/QlikView/Syntax-issues-on-getting-total-for-a-line/m-p/1000160#M340060</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Camile! Must remember for next time..!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 24 Sep 2015 07:59:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Syntax-issues-on-getting-total-for-a-line/m-p/1000160#M340060</guid>
      <dc:creator>Dayna</dc:creator>
      <dc:date>2015-09-24T07:59:04Z</dc:date>
    </item>
  </channel>
</rss>

