Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

selcukcadir
Contributor

bar chart sum last year total

hi all,

bar chart sum last year total

sum( {$<Year={"<=$(Year)-1"}>} value)

Dimensions : if(MonthYear >= '012013',MonthYear)

bar chart value :

012013 > 60

022013 > 60

032013 > 60

042013 > 60

052013 > 60

062013 > 60

072013 > 60

082013 > 60

092013 > 60

102013 > 60

112013 > 60

122013 > 60

12 Replies
rustyfishbones
Honored Contributor II

Re: bar chart sum last year total

try

SUM({<Year = {'$(=max(Year)-1)'}>}value)

Regards

Al

rustyfishbones
Honored Contributor II

Re: bar chart sum last year total

or you could try

2013-11-10_1444.png

selcukcadir
Contributor

Re: bar chart sum last year total

Hi Alan,

expression you sent ;  SUM({<Year = {'$(=max(Year)-1)'}>}value)

example2.png

should be ;

example.png

selcukcadir
Contributor

Re: bar chart sum last year total

Hi Alan,

expression you sent ;  SUM({<Year = {'$(=max(Year)-1)'}>}value)

example2.png

should be ;

example.png

rustyfishbones
Honored Contributor II

Re: bar chart sum last year total

so should it be

SUM({<Year = {'$(=max(Year))'}>}value)


which will give


2013-11-10_1449.png

selcukcadir
Contributor

Re: bar chart sum last year total

should be ;

I want to be like

example : 012013 value >> 2012 vales total 60

012013 > 60

022013 > 60

032013 > 60

042013 > 60

052013 > 60

062013 > 60

072013 > 60

082013 > 60

092013 > 60

102013 > 60

112013 > 60

122013 > 60

example3.png

rustyfishbones
Honored Contributor II

Re: bar chart sum last year total

so add TOTAL, something like

2013-11-10_1504.png

selcukcadir
Contributor

Re: bar chart sum last year total

Thanks Alan,

There is a more  problem with,

Year to day total

how can ?

example : bar chart Dimensions >> montyear 08-2013

< 08-2013 + > 01-2013

value YTD total > 80+70+60+50+40+30+20+10 = 360

example : bar chart Dimensions >> montyear 07-2013

value YTD total > 70+60+50+40+30+20+10 = 280

rustyfishbones
Honored Contributor II

Re: bar chart sum last year total

Hi,

See below, maybe this could get the result you need

2013-11-10_1629.png

Community Browser