Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

GetSelectedCount for date

Hi all,

I'm building a dashboard with couple of charts that are supposed to show the calculation of the measures for '2015-05-18' as default or basically when no date is selected until a date get selected from the bottom chart in the dashboard. I thought Getselectioncount

would be the easiest way of getting it right and it works to some extend when I select a date from the bottom chart but it doesnt show the correct sum by opening the dashboard or when no date selection is made.

Here is the formula that I'm using for the KPI that is in red.

Sum(${<EVENT_DATE={'$(=If(Getselectioncount({'EVENT_DATE'})='', {'2016-05-18'},{'EVENT_DATE'})'}>}

TOTAL_DISCREPANCY_VALUE_OVER)

Screen Shot 2016-06-23 at 2.02.55 PM.png

I'm totally stocked and appreciate any help...

Thank you.

Sara

4 Replies
swuehl
MVP
MVP

Please try to avoid posting the same topic multiple times.

It makes it hard to follow a discussion and clutters the forum.

GetSelectedCount for Date

rubenmarin

Hi Kandu, maybe you are trying to use GetSelectedCount()?

This function returns a number wich represent the number of different values selected in the field, so it returns zero when no values are selected.

Can you try this:

Sum(${<EVENT_DATE={'$(=Max(EVENT_DATE))'}>} TOTAL_DISCREPANCY_VALUE_OVER)

If one, more or no dates are selected, it will use the max date as the filter in set analysis. Or you want 2016-05-18 to be fixed?

Not applicable
Author

Sorry it took so long to publish that I thought I made a mistake and didnt press post. I tried your solution tho and it works perfect now. Thank you!

Sara

swuehl
MVP
MVP

Ok, no problem

Please set this thread to 'Assumed answered', too.