Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

souadouert
Contributor III

cumulative probleme

I have a problem, I have a table has two column ,

1-DATE:date_s

1-Indicateur :

SUM({<date_s,month={"<=$(=month)"},year={"=$(=MAX(year))"},PRODUIT = {"CREDITS"} , NATURE={"CREDIT A LA CONSOMMATION"}>}PRODUCTTION_VOLUME_TND),


indicateur is the it is the cumulative measure from January to the month displayed in the date column


i used this expression but the result is false, after the analyzes I noticed that the result is date = date and not cumulative

25 Replies
YoussefBelloum
Esteemed Contributor

Re: cumulative probleme

Hi,

you should use syntax like this:

=sum( {<date_s={">=01/01/2017  <=$(=max(date_s))"}>} PRODUCTTION_VOLUME_TND)

souadouert
Contributor III

Re: cumulative probleme

Hello youssef ,
I tested this expression but nothings changed because i have the date_s in the colunm So , the indicateur folow this date

YoussefBelloum
Esteemed Contributor

Re: cumulative probleme

try just to test it (add it on a textbox for example)

if yo have data like this for examples:

Date, Mois, Indicateur

01/01/2017, 01, 100

01/02/2017, 02, 300

16/03/2017, 03, 400

27/04/2017, 04, 150


if you select 16/03/2017 on the date listbox, you will have Sum = 800

if you select 01/02/2017 on the date listbox, you will have Sum = 400

avkeep01
Valued Contributor

Re: cumulative probleme

Hi Souad,

You could try:

RANGESUM(ABOVE(SUM({$<month={"<=$(=month)"},year={"=$(=MAX(year))"},PRODUIT = {"CREDITS"} , NATURE={"CREDIT A LA CONSOMMATION"}>}PRODUCTTION_VOLUME_TND),0,ROWNO(TOTAL)))



souadouert
Contributor III

Re: cumulative probleme

my date FORMAT is MM/YYYY,

souadouert
Contributor III

Re: cumulative probleme

it can causes problems

souadouert
Contributor III

Re: cumulative probleme

hello, van keep

this expression doesnt satisfaited my needs

YoussefBelloum
Esteemed Contributor

Re: cumulative probleme

no problem:


=sum( {<Date={">=01/2017  <=$(=max(Date))"}>} Indicateur)

souadouert
Contributor III

Re: cumulative probleme

Yes, i aleardy tested but no thing changed the problem is with th column date_s when i deleted , the indicator is true

Community Browser