Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi guys,
I am trying to write a set analysis for a combo chart which causes my chart to ignore any date selection on the dashboard. I have tried this:
=Sum({<[FuEm_SentDate]={"1(=Year([FuEm_SentDate])='2018')"}>}FuEm_Clicks)
But when I select 2017 the chart's bars and line disappears. Am I putting the 1 in the wrong place, or doing something else wrong?
Thanks in advance,
Gary
Hi Sunny-talwar, thanks for your solutions. Your second solution was almost correct.
=Sum({<[FuEm_SentYear] = {'2018'}, [FuEm_SentDate]>} FuEm_Clicks)
I just needed to place a 1 as the set modifier so as to ignore any dashboard selection, as below.
=Sum({1<[FuEm_SentYear] = {'2018'}, [FuEm_SentDate]>} FuEm_Clicks)
Now it works as expected.
Cheers
Gary
Try this
=Sum({<[FuEm_SentDate] = {"=Year(Only({1} [FuEm_SentDate])) = '2018'"}>} FuEm_Clicks)
But why don't you create a year field in the script like this
Year(FuEm_SentDate) as FuEm_SentYear
and then use this
=Sum({<[FuEm_SentYear] = {'2018'}, [FuEm_SentDate]>} FuEm_Clicks)
Thanks jontydkpi, but I'm trying to get the set analysis to ignore any date selection on the dashboard, and give the result of just 2018 on the chart. This does'nt do that.
Thanks
Gary
Thanks Sunny_talwar, your second solution makes sense. The first did'nt work. I am currently reloading the large dataset and will try your solution. But surely a 1 is needed somewhere as a set modifier, otherwise the chart line will disappear when I select 2017 in the dashboard.
Thanks
Gary
Hi Sunny-talwar, thanks for your solutions. Your second solution was almost correct.
=Sum({<[FuEm_SentYear] = {'2018'}, [FuEm_SentDate]>} FuEm_Clicks)
I just needed to place a 1 as the set modifier so as to ignore any dashboard selection, as below.
=Sum({1<[FuEm_SentYear] = {'2018'}, [FuEm_SentDate]>} FuEm_Clicks)
Now it works as expected.
Cheers
Gary