Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
samp
Contributor III
Contributor III

Not working as expected when I use normal count and set analysis count in if condition

Using below logic.

By default it should calculate last Quarter for all the years which looks fine for me, but when I select Year and Quarter Q1 I am getting Jan, Feb, Mar, Apr, May, Jun as below image instead Jan, Feb, Mar. Here I am using pivot chart with time drill Year-->Quarter.

if(GetSelectedCount(Year)>=1 or GetSelectedCount(Quarter)>=1, 

count(TimeSpent),

count({<Quarter={$(vLastQuarter)}>}TimeSpent))

It looks it is simple but I feel I am missing something.

For my testing count(TimeSpent) is working as expected, issue is when try to show defaults for last Quarter with the above logic.

appreciate for your help.

Not Ok if I select current Quarter:

img1.PNG

Ok if I select last Quarter  with the above if condition or simple count(TimeSpent).

img2.PNG

2 Replies
arvind_patil
Partner - Specialist III
Partner - Specialist III

Hi Sam,

Please  try below Expression:

count({<Quarter={'$(=maxString(Quarter))'}>}TimeSpent))


Thanks,

Arvind Patil

agigliotti
Partner - Champion
Partner - Champion

first of all check your variable vLastQuarter content using a textbox.