<?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 Subtracting grandtotal column from individual column in pivot in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Subtracting-grandtotal-column-from-individual-column-in-pivot/m-p/580170#M547869</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I need help with one of the problem I am trying to solve.&lt;/P&gt;&lt;P&gt;I have a pivot table pasted below:-&lt;/P&gt;&lt;P&gt;I have converted absolute revenue brought by each sales person brought within each discount percent interval(per int) into relative percentage using following formula:-&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[revenue]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;) / &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;Sum&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;total&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt; &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[sales person]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;&amp;gt; &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[revenue]&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt; &lt;IMG alt="Pivot help.png" class="jive-image" src="/legacyfs/online/53082_Pivot help.png" style="width: 620px; height: 349px;" /&gt;&lt;/P&gt;&lt;P&gt;Now I am trying to do peer comparison and for that I have to subtract Total from each column i.e Total - A, Total -B and so on.. so my Total should remain fixed. I tried using following code but I am not getting right values:-&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;Sum&lt;/SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[revenue]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;) / &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;Sum&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;total&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt; &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[Sales Person]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;&amp;gt; &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[Revenue]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;) - (&lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;Sum&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[revenue]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;) / &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;Sum&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;All&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt; &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[Per Int]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;&amp;gt; &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[revenue]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;)) &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;I was wondering if anybody have seen with this kind of situation.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;Kind Regards,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;Varun&lt;/SPAN&gt;&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>Thu, 13 Feb 2014 07:51:35 GMT</pubDate>
    <dc:creator />
    <dc:date>2014-02-13T07:51:35Z</dc:date>
    <item>
      <title>Subtracting grandtotal column from individual column in pivot</title>
      <link>https://community.qlik.com/t5/QlikView/Subtracting-grandtotal-column-from-individual-column-in-pivot/m-p/580170#M547869</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I need help with one of the problem I am trying to solve.&lt;/P&gt;&lt;P&gt;I have a pivot table pasted below:-&lt;/P&gt;&lt;P&gt;I have converted absolute revenue brought by each sales person brought within each discount percent interval(per int) into relative percentage using following formula:-&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[revenue]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;) / &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;Sum&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;total&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt; &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[sales person]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;&amp;gt; &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[revenue]&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt; &lt;IMG alt="Pivot help.png" class="jive-image" src="/legacyfs/online/53082_Pivot help.png" style="width: 620px; height: 349px;" /&gt;&lt;/P&gt;&lt;P&gt;Now I am trying to do peer comparison and for that I have to subtract Total from each column i.e Total - A, Total -B and so on.. so my Total should remain fixed. I tried using following code but I am not getting right values:-&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;Sum&lt;/SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[revenue]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;) / &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;Sum&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;total&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt; &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[Sales Person]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;&amp;gt; &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[Revenue]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;) - (&lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;Sum&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[revenue]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;) / &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;Sum&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;All&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt; &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[Per Int]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;&amp;gt; &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[revenue]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;)) &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;I was wondering if anybody have seen with this kind of situation.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;Kind Regards,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;Varun&lt;/SPAN&gt;&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>Thu, 13 Feb 2014 07:51:35 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subtracting-grandtotal-column-from-individual-column-in-pivot/m-p/580170#M547869</guid>
      <dc:creator />
      <dc:date>2014-02-13T07:51:35Z</dc:date>
    </item>
  </channel>
</rss>

