5 Replies Latest reply: Aug 19, 2016 5:35 AM by Shazad Nazir

# Current Fiscal Year Revenue & Last Fiscal Year Revenue

Hi Experts,

While calculating the Revenue for Current and Last fiscal year:

Variable is being used are as follows:

1. CurrentYear  Expression: Max(Right(FiscalYear,4)) -1 & '-' & Max(Right(FiscalYear,4)) Resultant > 2015-2016
2. LastYear Expression: Max(Right(FiscalYear,4)) -2 & '-' & (Max(Right(FiscalYear,4))-1)  Resultant > 2014-2015

Variables result has been tested by pasting them in charts > KPI.

Master Items Created with Expressions as follows:

1. RevCurrentYear Expression:
1. Sum({<FiscalYear = {'\$(CurrentYear)'}>}RowTotal) Does not work
2. Sum({<FiscalYear = {'2015-2016'}>}RowTotal) works fine
2. RevLastYear Expression:
1. Sum({<FiscalYear = {'\$(LastYear)'}>}RowTotal) Does not work
2. Sum({<FiscalYear={'2014-2015'} >} RowTotal) works fine

• ###### Re: Current Fiscal Year Revenue & Last Fiscal Year Revenue

Hi,

This is just off the top of my head but try:

Sum({<FiscalYear = {"=\$(CurrentYear)"}>}RowTotal)

• ###### Re: Current Fiscal Year Revenue & Last Fiscal Year Revenue

Ok so the simplest way is to use:

=Sum({<FiscalYear = {'\$(CurrentYear)'}>}RowTotal)

But whack an = on the start of your variable definition

=Max(Right(FiscalYear,4)) -1 & '-' & Max(Right(FiscalYear,4))

• ###### Re: Current Fiscal Year Revenue & Last Fiscal Year Revenue

Can you try one of these:

Sum({<FiscalYear = {'\$(=\$(CurrentYear))'}>}RowTotal)

Sum({<FiscalYear = {'\$(=(LastYear))'}>}RowTotal)

or

Sum({<FiscalYear = {'\$(=CurrentYear)'}>}RowTotal)

Sum({<FiscalYear = {'\$(=LastYear)'}>}RowTotal)

• ###### Re: Current Fiscal Year Revenue & Last Fiscal Year Revenue

Thanks, it worked.

• ###### Re: Current Fiscal Year Revenue & Last Fiscal Year Revenue

Hi Sunny,

While using the all the three measures in same "LineChart", in Legends System shows

• CY (Current Year)
• LY (Last Year)
• SLY (Second Last Year)

How can I display year number i.e. variable value 2015-2016 .... 2014-2015 ... 2014-2013 in Chart Legends ?