Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
louwriet
Creator
Creator

Calculated dimension Daterange with variables

Hi All,

Would appreciate some guidance with a calcualted dimension. One of my dimensions is year month. Year month have values for 5 years like 201001 201002 201003........ 201503. I have a line chart that i would like to display the last 12 months only. So when user select for instance 2013 in year list box, the yearmonth variables change correctly. So variables is fine, the calculated dimension is the problem

I am trying to create a calculated dimension with dates greater and less than two variables. The variables values have values 201404 and 201503

my calcualted dimension

= if ({< yearmonth = {">=$(= vminyearmonth ) <= &(= vmaxyearmonth)">}, yearmonth, null() )

Then what i would do is check the "supress when value is null" to only show yearmonths between this range.

Thank you

Regards

Louw

3 Replies
alexandros17
Partner - Champion III
Partner - Champion III

Good job, it should work, what's the question?

louwriet
Creator
Creator
Author

Alessandro it is not working.  Also above  the & is actually a $ in my code.

I need help with the calculated dimension so that it works the way i want it to work.

thank you

alexandros17
Partner - Champion III
Partner - Champion III

Try this:

= if ($ {<yearmonth = {'>=$(vminyearmonth)<=$(vmaxyearmonth)'}>}, yearmonth, null() )

if still doesn't work try with:

= if ($ {<yearmonth = {'>=vminyearmonth<=vmaxyearmonth'}>}, yearmonth, null() )

let me know