Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello Experts,
I am trying to write a simple expression where when a user selects year dimension, it should show the December data, likewise if he selects 3 months (eg: Aug, Sep, Oct), the last month 'Oct' of his selection should show the data.
year and month are my dimensions...
I am trying the below expression... can anyone help with this please....
=if($(vExpressionCond),
if
(sum({<month = {'=$max(month)'}>}reportValue)<>0,
num
(sum({<month = {'=$max(month)'}>}reportValue),
$(vNumberForm)),''))
Thanks in advance,
Mady
I currently also struggle with month as name and max(month)...
I got it working with a additional monthID, please see attached.
Stefan
Stefan,
In your application, when i select a year 2010 it shows all months except Jan... I want to see Dec selected when I click on 2010 and like wise, if i select feb, mrz, apr then I should see Apr as this is the maximum from what i selected.. I have the same situation what you have tried here and I can see the number, but not able to make it work.
Thank you again for your time and patience, any more suggestions please?
Hi Mady,
in my example, the expression we discussed affects only the textbox ("Summe =" / sum of values).
If you select a year, the sum is correctly displaying only dec value.
I always understood that this was your requirement.
So you want also preselect within listboxes?
Would really be good if you could post an example or rework mine...
Regards,
Stefan
Hello Stefan,
Thats exactly what I was looking for but was confused by looking at the title of the chart columns. Can you help me set up the title for the charts... I mean when I select the date(max(month_num),'MMM') expecting to see the name of the month, it returns Jan instead of Dec... any suggestions please..
Previously I was confused because of the chart Titles... but I am half way through with the issue...
Thanks again for all your time spent.
Hello Stefan,
Nevermind I found the solution to use it as a Header in chart and solved it. Below is the expression if you need it for reference.
='Month Actual ' & pick(max(month_num),'Jan','Feb','Mar','Apr','May','Jun','Jul','Aug','Sep','Oct','Nov','Dec') & ' ' & year
Thanks again for all your time and effort.
Mady
Sorry, I got lost in translation...
Do you mean, if you select 2012, ypu expect Dec but you are actually getting Jan?
Thats because my Dates range from Feb 2010 to Jan 2012 (I forgot a -1 in my script, autogenerating the Dates).
Is that's what is confusing you?
Stefan
Hello Stefan,
No even in my script, when I am using the expression for chart Title, it shows me max(month_ Num) as 12, but the name as Jan instead of December, which was annoying so I have kind of hard coded it for now and solved the problem. I was not talking about your application months.
Thanks Again,
Mady