<?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: Sum expression returns 0 in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Sum-expression-returns-0/m-p/1654218#M48879</link>
    <description>&lt;P&gt;Hi Jaime,&lt;/P&gt;&lt;P&gt;Thank you for your reply.&lt;/P&gt;&lt;P&gt;I followed your tips and now the KPI shows something but info in table is wrong since it shows the character "?" as you can see in the following picture:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="capture14.png" style="width: 715px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/24933iE060A0DDAE13A85D/image-size/large?v=v2&amp;amp;px=999" role="button" title="capture14.png" alt="capture14.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Thank again.&lt;/P&gt;</description>
    <pubDate>Wed, 04 Dec 2019 16:46:07 GMT</pubDate>
    <dc:creator>mtabernad</dc:creator>
    <dc:date>2019-12-04T16:46:07Z</dc:date>
    <item>
      <title>Sum expression returns 0</title>
      <link>https://community.qlik.com/t5/App-Development/Sum-expression-returns-0/m-p/1654100#M48867</link>
      <description>&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;I am trying to sum my "cpu" field but it returns 0. I tried 'sum(num(cpu))' and also 'sum(cpu)' but it doesn't work. Plus, I changed my load script to "num(cpu) as cpu" but problem persists.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="capture13.png" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/24913i2136F61208827954/image-size/large?v=v2&amp;amp;px=999" role="button" title="capture13.png" alt="capture13.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Any ideas?&lt;/P&gt;&lt;P&gt;Thank you in advance.&lt;/P&gt;</description>
      <pubDate>Sat, 16 Nov 2024 03:55:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Sum-expression-returns-0/m-p/1654100#M48867</guid>
      <dc:creator>mtabernad</dc:creator>
      <dc:date>2024-11-16T03:55:53Z</dc:date>
    </item>
    <item>
      <title>Re: Sum expression returns 0</title>
      <link>https://community.qlik.com/t5/App-Development/Sum-expression-returns-0/m-p/1654140#M48870</link>
      <description>&lt;P&gt;Hi!&lt;/P&gt;&lt;P&gt;Your field "cpu" is not being&amp;nbsp;&lt;STRONG&gt;interpreted&lt;/STRONG&gt; correctly as a number. The clue is that it is indented on the left in your table: it indicates it is a text.&lt;/P&gt;&lt;P&gt;Note that I said "Interpreted" but not "&lt;STRONG&gt;formated&lt;/STRONG&gt;". Num() is a format function but you need to tell Qlik Sense how to interpret that "1.63". I bet the problem is in the dot: surely your language configuration uses comma as decimal separator! If so is right (check the system variable "DecimalSep" at the beginning of your load script), then try the following in the script side:&lt;/P&gt;&lt;P&gt;Load&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; Num(Num#(cpu, '#.#','.',',')) as cpu&lt;/P&gt;&lt;P&gt;[...]&lt;/P&gt;&lt;P&gt;I use Num# to tell Qlik Sense how to interpret the input string as a number and then I use Num to make it look as a number (following the regional especifications).&lt;/P&gt;&lt;P&gt;Hope it helps!&lt;/P&gt;&lt;P&gt;Jaime.&lt;/P&gt;</description>
      <pubDate>Wed, 04 Dec 2019 14:46:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Sum-expression-returns-0/m-p/1654140#M48870</guid>
      <dc:creator>jaibau1993</dc:creator>
      <dc:date>2019-12-04T14:46:22Z</dc:date>
    </item>
    <item>
      <title>Re: Sum expression returns 0</title>
      <link>https://community.qlik.com/t5/App-Development/Sum-expression-returns-0/m-p/1654218#M48879</link>
      <description>&lt;P&gt;Hi Jaime,&lt;/P&gt;&lt;P&gt;Thank you for your reply.&lt;/P&gt;&lt;P&gt;I followed your tips and now the KPI shows something but info in table is wrong since it shows the character "?" as you can see in the following picture:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="capture14.png" style="width: 715px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/24933iE060A0DDAE13A85D/image-size/large?v=v2&amp;amp;px=999" role="button" title="capture14.png" alt="capture14.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Thank again.&lt;/P&gt;</description>
      <pubDate>Wed, 04 Dec 2019 16:46:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Sum-expression-returns-0/m-p/1654218#M48879</guid>
      <dc:creator>mtabernad</dc:creator>
      <dc:date>2019-12-04T16:46:07Z</dc:date>
    </item>
    <item>
      <title>Re: Sum expression returns 0</title>
      <link>https://community.qlik.com/t5/App-Development/Sum-expression-returns-0/m-p/1654422#M48898</link>
      <description>&lt;P&gt;Hi!&lt;/P&gt;&lt;P&gt;As far as I know, Qlik Sense do not use that '?' symbol when something does not work (QS just sets the wrong value as Null). Thus, I bet those '?' came as '?' from your data source. Whatsmore, since your KPI now shows a number, that means that there are numbers among the values of cpu!&lt;/P&gt;&lt;P&gt;Said so, load your cpu field as it is in your data source and explore its content. Remember that you should always perform an exploratory data analysis.&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;Jaime.&lt;/P&gt;</description>
      <pubDate>Thu, 05 Dec 2019 07:33:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Sum-expression-returns-0/m-p/1654422#M48898</guid>
      <dc:creator>jaibau1993</dc:creator>
      <dc:date>2019-12-05T07:33:41Z</dc:date>
    </item>
    <item>
      <title>Re: Sum expression returns 0</title>
      <link>https://community.qlik.com/t5/App-Development/Sum-expression-returns-0/m-p/1654464#M48901</link>
      <description>&lt;P&gt;Hi Jaime,&lt;/P&gt;&lt;P&gt;I looked for some info about "?" symbol displayed in a QS table and it seems to be a problem related to format again:&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.qlik.com/t5/QlikView-Connectors/Multiple-Question-mark-in-list-box/m-p/297156" target="_blank"&gt;https://community.qlik.com/t5/QlikView-Connectors/Multiple-Question-mark-in-list-box/m-p/297156&lt;/A&gt;&lt;/P&gt;&lt;P&gt;It is solved adding the "text" function, but if I do that in load script:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;text(Num(Num#(cpu, '#.#','.',','))) as cpu&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;It is solved because data shows up in the table but in text format again and then the KPI&amp;nbsp;&lt;EM&gt;sum(cpu)&amp;nbsp;&lt;/EM&gt;doesn't work (back to original problem of the post)&lt;/P&gt;&lt;P&gt;So if I use text format, info show up in table but not in the KPI. And if I use number format, info show up in KPI but not in the table.&lt;/P&gt;&lt;P&gt;cpu field does not contain any '?' in its source format, so it's a problem from Qlik.&lt;/P&gt;&lt;P&gt;I'm going to try to change the format in the source to number format. Anyway, new ideas are welcome.&lt;/P&gt;&lt;P&gt;Thank you Jaime, I appreciate your time.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 05 Dec 2019 09:20:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Sum-expression-returns-0/m-p/1654464#M48901</guid>
      <dc:creator>mtabernad</dc:creator>
      <dc:date>2019-12-05T09:20:53Z</dc:date>
    </item>
    <item>
      <title>Re: Sum expression returns 0</title>
      <link>https://community.qlik.com/t5/App-Development/Sum-expression-returns-0/m-p/1654468#M48902</link>
      <description>&lt;P&gt;Quite weird, I had never listened about that '?'. If you can share a sample app maybe I can help you a bit more. Let me know how you finally solve it, otherwise.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Jaime.&lt;/P&gt;</description>
      <pubDate>Thu, 05 Dec 2019 09:30:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Sum-expression-returns-0/m-p/1654468#M48902</guid>
      <dc:creator>jaibau1993</dc:creator>
      <dc:date>2019-12-05T09:30:26Z</dc:date>
    </item>
    <item>
      <title>Re: Sum expression returns 0</title>
      <link>https://community.qlik.com/t5/App-Development/Sum-expression-returns-0/m-p/1654479#M48903</link>
      <description>&lt;P&gt;Are you loading field cpu from more than one data source, or more than one load statement? As John W and I discovered when we looked at this a few years ago, a mix of text and numerics can sometimes confuse the type inference logic in QV/QS.&lt;/P&gt;</description>
      <pubDate>Thu, 05 Dec 2019 09:54:44 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Sum-expression-returns-0/m-p/1654479#M48903</guid>
      <dc:creator>jonathandienst</dc:creator>
      <dc:date>2019-12-05T09:54:44Z</dc:date>
    </item>
    <item>
      <title>Re: Sum expression returns 0</title>
      <link>https://community.qlik.com/t5/App-Development/Sum-expression-returns-0/m-p/1654484#M48904</link>
      <description>&lt;P&gt;I solved it changing the format in the SQL Server, but wasn't able to do it in QS. Now info show up in the right side of the QS table and the KPI is calculated properly.&lt;/P&gt;&lt;P&gt;Thank you.&lt;/P&gt;&lt;P&gt;Regards.&lt;/P&gt;</description>
      <pubDate>Thu, 05 Dec 2019 09:59:16 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Sum-expression-returns-0/m-p/1654484#M48904</guid>
      <dc:creator>mtabernad</dc:creator>
      <dc:date>2019-12-05T09:59:16Z</dc:date>
    </item>
    <item>
      <title>Re: Sum expression returns 0</title>
      <link>https://community.qlik.com/t5/App-Development/Sum-expression-returns-0/m-p/1654541#M48915</link>
      <description>&lt;P&gt;No, I am loading this filed just from one SQL instance. Weird... Anyway I solved it changing the format in SQL Server instance.&lt;/P&gt;&lt;P&gt;Thank you anyway!&lt;/P&gt;</description>
      <pubDate>Thu, 05 Dec 2019 11:45:24 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Sum-expression-returns-0/m-p/1654541#M48915</guid>
      <dc:creator>mtabernad</dc:creator>
      <dc:date>2019-12-05T11:45:24Z</dc:date>
    </item>
  </channel>
</rss>

