Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
COUNT({$<TIME_Year_Month_num={$(=MAX(TIME_Year_Month_num))},TIME_Year= ,TIME_Month_Num= ,RACKER_Above_Max={$(='Y')}>}COMPA_RATIO_BIN)
I'm using this (^) expression to create a bar chart of values in COMPA_RATIO_BIN. I only want to count and display the values in the latest month in the latest year of my data. To identify this latest month in the latest year, I've created [TIME_Year_Month_num] which is a concatenation of the year with a 2-digit month number (e.g. for September of 2012, [TIME_Year_Month_num] = 201209).
The problem is, when I make selections in Month or Year listboxes, the data in the chart clearly changes. By my understanding of set analysis, this shouldn't happen because I've entered
TIME_Year=
TIME_Month_Num=
Thoughts?
Hi
COUNT({$<TIME_Year_Month_num={$(=MAX({1}TIME_Year_Month_num))},TIME_Year= ,TIME_Month_Num= ,RACKER_Above_Max={$(='Y')}>}COMPA_RATIO_BIN)
Hope it helps
See the {1} in max() function.
And also try mr.rebeccad post also..
Try using a 1 instead of the $ sign
Hi
COUNT({$<TIME_Year_Month_num={$(=MAX({1}TIME_Year_Month_num))},TIME_Year= ,TIME_Month_Num= ,RACKER_Above_Max={$(='Y')}>}COMPA_RATIO_BIN)
Hope it helps
See the {1} in max() function.
And also try mr.rebeccad post also..
Silly Mayil, I am a girl!!
a) Thanks for the ultra-quick reply
b) I'd rather not use a 1 because I have other list boxes (besides year and month) that I'd like to let change the data
c) I tried using a 1 just to see what would happen. All of the list box filters EXCEPT for year and month are ignored. Could this somehow be due to the fact that I use month and year to define TIME_Year_Month_num in my script?
Hi
Oops. really sorry rebeccad, am from India..I didn't heard this name before.
You can use max(TOTAL datefield) if you want it to always take the absolute max, despite what is selected.
No problem I just thought it was funny
Mayil,
Thanks. That worked perfectly. But can you explain what that {1} does and why it worked?
Hi mhouston00
=max({1}TimeYearNum) holds the maximum Year n ignore any selection in the filters.
And remaining values, it change according to your selection.
For rebeccad:
.