<?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 Count Sum in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Count-Sum/m-p/87423#M14281</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Is it possible to count the sum of one metric compared to the sum of another?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Currently, this is my expression:&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;Count&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;DISTINCT&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt; {&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;%Order&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;={&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;"=QtyOrd=QtyShip"&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;},&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;ShipMethod&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;={'SO'},&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;OrderDisposition&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;-={'W'}&amp;gt;} &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;OrderNumber&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;)&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;It isn't giving me the right result.&amp;nbsp; I was thinking if I could compare the sum of QtyOrd to the sum of QtyShip, it might work correctly...&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;Thanks in advance.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 15 Aug 2018 13:46:41 GMT</pubDate>
    <dc:creator>lfholland</dc:creator>
    <dc:date>2018-08-15T13:46:41Z</dc:date>
    <item>
      <title>Count Sum</title>
      <link>https://community.qlik.com/t5/QlikView/Count-Sum/m-p/87423#M14281</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Is it possible to count the sum of one metric compared to the sum of another?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Currently, this is my expression:&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;Count&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;DISTINCT&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt; {&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;%Order&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;={&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;"=QtyOrd=QtyShip"&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;},&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;ShipMethod&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;={'SO'},&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;OrderDisposition&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;-={'W'}&amp;gt;} &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;OrderNumber&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;)&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;It isn't giving me the right result.&amp;nbsp; I was thinking if I could compare the sum of QtyOrd to the sum of QtyShip, it might work correctly...&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;Thanks in advance.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Aug 2018 13:46:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Count-Sum/m-p/87423#M14281</guid>
      <dc:creator>lfholland</dc:creator>
      <dc:date>2018-08-15T13:46:41Z</dc:date>
    </item>
    <item>
      <title>Re: Count Sum</title>
      <link>https://community.qlik.com/t5/QlikView/Count-Sum/m-p/87424#M14282</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You mean this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Count(DISTINCT {&amp;lt;%Order={"=&lt;SPAN style="color: #ff0000;"&gt;Sum&lt;/SPAN&gt;(QtyOrd)=&lt;SPAN style="color: #ff0000;"&gt;Sum&lt;/SPAN&gt;(QtyShip)"}, ShipMethod={'SO'}, OrderDisposition-={'W'}&amp;gt;} OrderNumber)&lt;/STRONG&gt;&lt;SPAN style="font-size: 8pt; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Aug 2018 13:54:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Count-Sum/m-p/87424#M14282</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2018-08-15T13:54:56Z</dc:date>
    </item>
    <item>
      <title>Re: Count Sum</title>
      <link>https://community.qlik.com/t5/QlikView/Count-Sum/m-p/87425#M14283</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;A key is never a good field to use for any calculation purpose. The % as the first character of %Order indicate to me that this is a key.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think that&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Count(DISTINCT {&amp;lt;OrderNumber={"=QtyOrd=QtyShip"},ShipMethod={'SO'},OrderDisposition={'W'}&amp;gt;} OrderNumber)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;might work for you...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But it depends on the fact that OrderNumber must be a unique row identificator in relation to the two fields QtyOrd and QtyShip. If not it will return a wrong count.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Aug 2018 13:56:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Count-Sum/m-p/87425#M14283</guid>
      <dc:creator>petter</dc:creator>
      <dc:date>2018-08-15T13:56:12Z</dc:date>
    </item>
    <item>
      <title>Re: Count Sum</title>
      <link>https://community.qlik.com/t5/QlikView/Count-Sum/m-p/87426#M14284</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;%Order is a key but it is also the unique identifier.&amp;nbsp; Should I load another field that is %Order with a different name?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Aug 2018 14:02:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Count-Sum/m-p/87426#M14284</guid>
      <dc:creator>lfholland</dc:creator>
      <dc:date>2018-08-15T14:02:57Z</dc:date>
    </item>
    <item>
      <title>Re: Count Sum</title>
      <link>https://community.qlik.com/t5/QlikView/Count-Sum/m-p/87427#M14285</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;As long as it is a key it will appear in another table and then it will not be something that acts as a normal row identifier since a key field straddles two or more tables and might very well have a lot of extra values from the other tables....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So yes you will have to have some non-key row identifier to do the calculation in the search correctly if you are not using aggregates like Sunny showed you.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Aug 2018 14:44:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Count-Sum/m-p/87427#M14285</guid>
      <dc:creator>petter</dc:creator>
      <dc:date>2018-08-15T14:44:46Z</dc:date>
    </item>
  </channel>
</rss>

