Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
In dimension for showing trends of last 6 quarters, last 6 months and last 30 days according to dropdown selections, we have created a expression using pick and match and in measure we have used set analysis...we are getting correct data but for 2 quarters there is no data and we want that zero data as well ....if we use if condition we are getting the required visualization but facing this problem with set analysis
dimension expression: = pick(match('$(vPeriod)','Monthly','Quarterly'','Daily'),RollingMonth,QT,RollingDate)
here vPeriod is variable whose values change according to dropdown selections ('Monthly','Quarterly','Daily') and Rollingmonth field contains last 6 months ,RollingDate field contains last 30 days and QT contains quarters
measure expression: (count(distinct {$<RED_FLAG ={1}>} [AT_PROJECTID] ))
if RED_FLAG=1 we want count of distinct PID's
Kindly provide any solution to include zero data points in chart
Thanks in Advance🙂
Hi @brunobertels ,
Thank You for your reply
It isn't worked for me but I found one solution for this
(count(distinct {$<RED_FLAG={1}>} [AT_PROJECTID] )) + Count(DISTINCT [AT_PROJECTID])*0
Hi
not sure but may be like this
(
count(distinct {$<RED_FLAG ={1}>} [AT_PROJECTID] )
+0 *
count( {1} distinct {$<RED_FLAG ={1}>} [AT_PROJECTID] )
)
Hi,
Thanks for reply ... with your solution we are getting data where we are expecting zero data for 2 quarters and getting unexpected high data for other 4 quarters as well
Kindly help!
ok
Have you tried to agregate your mesure with aggr() function
(
aggr(count(distinct {$<RED_FLAG ={1}>} [AT_PROJECTID] ),$(vPeriod))
+0 *
aggr(count( {1} distinct {$<RED_FLAG ={1}>} [AT_PROJECTID] ),$(vPeriod))
)
Hi @brunobertels ,
Thank You for your reply
It isn't worked for me but I found one solution for this
(count(distinct {$<RED_FLAG={1}>} [AT_PROJECTID] )) + Count(DISTINCT [AT_PROJECTID])*0