Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
kunkumnaveen
Specialist
Specialist

select date to min date

Hello All

i need help in writing down a expression  to get  values b/w  min date to  current selected   in comparative analysis,

let say if i got  a sample data like this:

date           value    

1 jan            100

2 jan             200

3 jan             300

4 jan             400

from a calendar object(which is under group1)  if i select 4 jan then i should get sum of values from 1 jan to 4 jan (100+200+300+400),

if 3 jan then 1 jan to 3 jan(100+200+300)..

for this the variable i had written :

vmin='1 jan';

vmax=max({group1}date).....i tested it in a textbox ,if i use this=$(vmax),it throwing me error ,then if i use this=vmax i am getting value

then i wrote expression like

sum({group1<date={">=$(vmin)<=$(vmax)"}>}value)  (which is not working)

plz any suggestions

7 Replies
MindaugasBacius
Partner - Specialist III
Partner - Specialist III

Try this:

sum({group1<date={">=$(=vmin)<=$(=vmax)"}>}value)
kunkumnaveen
Specialist
Specialist
Author

thanks for ur reply ,

but its not working bro....

MindaugasBacius
Partner - Specialist III
Partner - Specialist III

sum({<date={">=$(=vmin)<=$(=vmax)"}>}value)

What about when removing group1?

ramoncova06
Specialist III
Specialist III

remove the equal sign "=" from the variable you can change the expresion to

sum({group1<date={">=$(=vmin)<=$(=vmax)"}>}value)

kunkumnaveen
Specialist
Specialist
Author

still looking for suggestions

MindaugasBacius
Partner - Specialist III
Partner - Specialist III

Could you please attach qvw?

kunkumnaveen
Specialist
Specialist
Author

Hi,

plz find attachment with sample data,

Note:i want it to  be work by applying groups only

thanks