Skip to Content
avatar image
Former Member

Showing Previous years and Current year data in the same view.

Hi All,

I am trying to create a Script Calculation View . On top of the view I have to create a WebI report.

I have a requirement wherein I have to show the data for all the months for the selected year (in Prompt). In the same table I have to show the data for the month of December for the previous 6 years in 6 different columns.

E.g. If I enter 2016 then monthly data for 2016 (Jan to Dec) and December’s data for 2015, 14, 13, 12, 11, 10.

The issue is when I use Variable, it filters the table for that particular year and I am unable to show the other years data.

I tried using Input Parameter/Placeholder as well; however got no luck.

Could you please help me out. I am new in this technology.

I am using the following logic:


var_out =









CaseWhen"YEAR"=:Year-6 and"MONTH"='Dec'Then"Actual_Fc_Dec"End"Last_Year6",

CaseWhen"YEAR"=:Year-5 and"MONTH"='Dec'Then"Actual_Fc_Dec"End"Last_Year5",

CaseWhen"YEAR"=:Year-4 and"MONTH"='Dec'Then"Actual_Fc_Dec"End"Last_Year4",

CaseWhen"YEAR"=:Year-3 and"MONTH"='Dec'Then"Actual_Fc_Dec"End"Last_Year3",

CaseWhen"YEAR"=:Year-2 and"MONTH"='Dec'Then"Actual_Fc_Dec"End"Last_Year2",

CaseWhen"YEAR"=:Year-1 and"MONTH"='Dec'Then"Actual_Fc_Dec"End"Last_Year1",


















--(PLACEHOLDER."$$YEAR$$" => :Year,


--('PLACEHOLDER' = ('$$Year$$', ''),



* Year is Input Parameter.
* Have commented the placeholder.
View is validating fine


Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • avatar image
    Former Member
    Oct 10, 2017 at 05:42 AM

    Hi All,

    Any update?


    Add comment
    10|10000 characters needed characters exceeded