<?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: Difference between expressions using sum and total in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Difference-between-expressions-using-sum-and-total/m-p/831393#M1003310</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;actually, you should try this out with some very simple sample data in Excel so that you exactly see what is happening. If you are not familiar with the expressions, there might be even more pitfalls to consider in developing the right approach for your objective. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 22 May 2015 06:43:58 GMT</pubDate>
    <dc:creator>danieloberbilli</dc:creator>
    <dc:date>2015-05-22T06:43:58Z</dc:date>
    <item>
      <title>Difference between expressions using sum and total</title>
      <link>https://community.qlik.com/t5/QlikView/Difference-between-expressions-using-sum-and-total/m-p/831389#M1003306</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;I am trying to understand a line graph with dimension = Period_id, where Period_id contains values of week numbers like 2015-10, 2015-11, 2015-12..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm trying to understand the difference between the below two expressions when used on the same graph. Are both trying to achieve the same thing?&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 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;Period_id&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;&amp;gt; &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;FABS&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[SHIPMENT_FRCST_WEEK_N]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;-&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;SHIPMENT_QTY&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;)) &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt; &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;FABS&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;[SHIPMENT_FRCST_WEEK_N]&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;SHIPMENT_QTY&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;)) &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;Thanks for your help &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 22 May 2015 06:03:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Difference-between-expressions-using-sum-and-total/m-p/831389#M1003306</guid>
      <dc:creator />
      <dc:date>2015-05-22T06:03:57Z</dc:date>
    </item>
    <item>
      <title>Re: Difference between expressions using sum and total</title>
      <link>https://community.qlik.com/t5/QlikView/Difference-between-expressions-using-sum-and-total/m-p/831390#M1003307</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If the word &lt;STRONG&gt;total&lt;/STRONG&gt; comes in an &lt;EM&gt;expression&lt;/EM&gt;, the calculation will be made over all possible values given the current selections, &lt;SPAN style="text-decoration: underline;"&gt;but disregarding the chart dimensions&lt;/SPAN&gt;. Hence for your&amp;nbsp; &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;Period_id&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;&amp;gt;&amp;nbsp; &lt;/SPAN&gt;part of expression, the expression result will be given without considering the vaules of Period_id dimension (all same across Period_id). Hope this helps.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 22 May 2015 06:18:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Difference-between-expressions-using-sum-and-total/m-p/831390#M1003307</guid>
      <dc:creator>tresB</dc:creator>
      <dc:date>2015-05-22T06:18:07Z</dc:date>
    </item>
    <item>
      <title>Re: Difference between expressions using sum and total</title>
      <link>https://community.qlik.com/t5/QlikView/Difference-between-expressions-using-sum-and-total/m-p/831391#M1003308</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Sum(TOTAL&amp;lt;Period_id&amp;gt; FABS([SHIPMENT_FRCST_WEEK_N]-SHIPMENT_QTY)) &lt;/P&gt;&lt;P&gt;sum of absolute value of variance (field1-field2) with disregarding all dimensions except Period_id&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FABS(sum({$} [SHIPMENT_FRCST_WEEK_N]) - sum({$} SHIPMENT_QTY)) &lt;/P&gt;&lt;P&gt;absolute value of difference between total sum of field1&amp;nbsp; and total sum of field2&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;not sure what the intention of each one was &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 22 May 2015 06:18:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Difference-between-expressions-using-sum-and-total/m-p/831391#M1003308</guid>
      <dc:creator>danieloberbilli</dc:creator>
      <dc:date>2015-05-22T06:18:59Z</dc:date>
    </item>
    <item>
      <title>Re: Difference between expressions using sum and total</title>
      <link>https://community.qlik.com/t5/QlikView/Difference-between-expressions-using-sum-and-total/m-p/831392#M1003309</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;thanks for your replies. The graph should calculate the following KPI with dimension = Period_id.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The portion of code written is trying to achieve the (Absolute of SHIPMENT_FRCST_WEEK_N - SHIPMENT_QTY) &lt;/P&gt;&lt;P&gt;&lt;IMG alt="formula.jpg" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/87237_formula.jpg" style="width: 620px; height: 348px;" /&gt;&lt;/P&gt;&lt;P&gt;Which one of the 2 following is correct?&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 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;Period_id&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;&amp;gt; &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;FABS&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[SHIPMENT_FRCST_WEEK_N]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;-&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;SHIPMENT_QTY&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;)) &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&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;FABS&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;[SHIPMENT_FRCST_WEEK_N]&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;SHIPMENT_QTY&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;)) &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 22 May 2015 06:38:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Difference-between-expressions-using-sum-and-total/m-p/831392#M1003309</guid>
      <dc:creator />
      <dc:date>2015-05-22T06:38:53Z</dc:date>
    </item>
    <item>
      <title>Re: Difference between expressions using sum and total</title>
      <link>https://community.qlik.com/t5/QlikView/Difference-between-expressions-using-sum-and-total/m-p/831393#M1003310</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;actually, you should try this out with some very simple sample data in Excel so that you exactly see what is happening. If you are not familiar with the expressions, there might be even more pitfalls to consider in developing the right approach for your objective. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 22 May 2015 06:43:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Difference-between-expressions-using-sum-and-total/m-p/831393#M1003310</guid>
      <dc:creator>danieloberbilli</dc:creator>
      <dc:date>2015-05-22T06:43:58Z</dc:date>
    </item>
    <item>
      <title>Re: Difference between expressions using sum and total</title>
      <link>https://community.qlik.com/t5/QlikView/Difference-between-expressions-using-sum-and-total/m-p/831394#M1003311</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Tresesco,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You mean that on the chart where x-axis value of Period_id = 2015-10, the y-value displayed will be the total of the difference between SHIPMENT_FRCST_WEEK_N and SHIPMENT_QTY fields for all existing Period_ids present in the qlikview application when i use the below:?&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 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;Period_id&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;&amp;gt; &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;FABS&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[SHIPMENT_FRCST_WEEK_N]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;-&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;SHIPMENT_QTY&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;)) &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 22 May 2015 06:47:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Difference-between-expressions-using-sum-and-total/m-p/831394#M1003311</guid>
      <dc:creator />
      <dc:date>2015-05-22T06:47:43Z</dc:date>
    </item>
  </channel>
</rss>

