Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I am trying to show only the last 3 months of data but it's not working. I believe it's because my date field is formatted like 'MMM-YYYY' but I cannot seem to figure out the right syntax to fix it. Any ideas? TIA!
count({<[EPIC_CAPACITY.QUEUE_MONTH]={">=$(= Date(AddMonths(Max(EPIC_CAPACITY.QUEUE_MONTH),-3))) <=$(=Max(EPIC_CAPACITY.QUEUE_MONTH))"}>} [EPIC_CAPACITY.Ticket #])
attached New Version
=count({<[EPIC_CAPACITY.QUEUE_MONTH]={">=$(= Date(addmonths(Date(Max(date#(EPIC_CAPACITY.QUEUE_MONTH,'MMM-YYYY')),'MMM-YYYY'),-3),'MMM-YYYY')) <=$(=Date(Max(date#(EPIC_CAPACITY.QUEUE_MONTH,'MMM-YYYY')),'MMM-YYYY'))"}>} [EPIC_CAPACITY.Ticket #])
attached New Version
=count({<[EPIC_CAPACITY.QUEUE_MONTH]={">=$(= Date(addmonths(Date(Max(date#(EPIC_CAPACITY.QUEUE_MONTH,'MMM-YYYY')),'MMM-YYYY'),-3),'MMM-YYYY')) <=$(=Date(Max(date#(EPIC_CAPACITY.QUEUE_MONTH,'MMM-YYYY')),'MMM-YYYY'))"}>} [EPIC_CAPACITY.Ticket #])
In your chart, instead of using the calculated dimension use EPIC_CAPACITY.CLASS_DAYS, which you have already created in the script and appears to have the sames values.
Next create 2 variables like:
vMaxMonth = Max(EPIC_CAPACITY.QUEUE_MONTH)
vMaxMonth_3 = Date(AddMonths(vMaxMonth, -2), 'MMM-YYYY')
Change your chart expression to:
Count({<[EPIC_CAPACITY.QUEUE_MONTH]={">=$(vMaxMonth_3) <=$(vMaxMonth)"}>} [EPIC_CAPACITY.Ticket #])