Qlik Community

Qlik Sense App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

Announcements
Qlik® Product Spotlight: Discover what’s possible. Get more from our products.
See for yourself. Register today.
Not applicable

sum column incorrect

I must load from a csv file to qlik sense a csv table in this way:

[dashboard_data]:

LOAD [giorno_full],

  [anno],

  [mese],

  [giorno],

  [cliente_id],

  [cliente],

  [zona_id],

  [zona],

  [struttura_id],

  [struttura],

  [area_id],

  [area],

  Num#(cost,'0.00') as costo,

  Num#(revenue,'0.00') as ricavo

FROM [lib://prove/dashboard_data.csv]

(txt, utf8, embedded labels, delimiter is ';', msq);

This is the head of the csv file:

"giorno_full";"anno";"mese";"giorno";"cliente_id";"cliente";"zona_id";"zona";"struttura_id";"struttura";"area_id";"area";"cost";"revenue"

"2014-06-13";2014;6;13;36;"DOLOMITI4U DI GHEDINI BRUNO";9;"Cortina d'Ampezzo";22;"Dolomiti4u";30;"Area Veneto 1";56.98;60.00

"2014-06-16";2014;6;16;36;"DOLOMITI4U DI GHEDINI BRUNO";9;"Cortina d'Ampezzo";22;"Dolomiti4u";30;"Area Veneto 1";77.93;88.00

"2014-06-18";2014;6;18;36;"DOLOMITI4U DI GHEDINI BRUNO";9;"Cortina d'Ampezzo";22;"Dolomiti4u";30;"Area Veneto 1";83.91;96.00

"2014-06-19";2014;6;19;36;"DOLOMITI4U DI GHEDINI BRUNO";9;"Cortina d'Ampezzo";22;"Dolomiti4u";30;"Area Veneto 1";24.06;0.00

However when I create a measure with "sum(revenue)" or "sum(cost) the sum is incorrect (incredibly high)... which are the reasons? There are other ways to find those sums?

Tags (1)
1 Solution

Accepted Solutions
MVP
MVP

Re: sum column incorrect

Is this also to high when you select e.g. a single date or record?

Could you show some samples how the numbers look like?

I've noticed that you are using num#() function interpret your numbers. Which settings for decimal and thousand separator are you using? Maybe it's helpful to make them explicite:

Num#(cost,'0.00','.',',') as costo,

  Num#(revenue,'0.00','.',',') as ricavo

4 Replies
MVP
MVP

Re: sum column incorrect

Is this also to high when you select e.g. a single date or record?

Could you show some samples how the numbers look like?

I've noticed that you are using num#() function interpret your numbers. Which settings for decimal and thousand separator are you using? Maybe it's helpful to make them explicite:

Num#(cost,'0.00','.',',') as costo,

  Num#(revenue,'0.00','.',',') as ricavo

Not applicable

Re: sum column incorrect

Hi Michele,

I am attaching an sample app. Please let me know the number is coming right or not as per your requirement.

Not applicable

Re: sum column incorrect

Ok thanks the answer is correct!

okolyug16
Contributor II

Re: sum column incorrect

Please mark Stefan's answer as CORRECT if it answered your question.

Thanks!