cancel
Showing results for 
Search instead for 
Did you mean: 

Default Year

nsandee
Participant
0 Kudos

Hello All,

I have a condition "Production Year Prompt" which Returns data for the selected production year and the year prior to it.

@Select(Production Date\Production Year Number) = @Prompt('Select Production Year','N','Production Date\Production Year Number',mono,free,) or

@Select(Production Date\Production Year Number) = @Prompt('Select Production Year','N','Production Date\Production Year Number',mono,free,) - 1

I have to implement "Default Year" to the exiting condition.  We are using BO 4.0 Sp5 and Teradata as backend. Any idea on how to implement in the existing code?

Thanks

Sandy

Accepted Solutions (0)

Answers (1)

Answers (1)

mhmohammed
Active Contributor
0 Kudos

Hi Sandy,

Which Year do you want to set as Default Year? I'm setting 2015 as default year in the below formula.

@Select(Production Date\Production Year Number) = @Prompt('Select Production Year','N','Production Date\Production Year Number',mono,free,{'2015'}) or

@Select(Production Date\Production Year Number) = @Prompt('Select Production Year','N','Production Date\Production Year Number',mono,free,{'2015'}) - 1


Thanks,
Mahboob Mohammed

nsandee
Participant
0 Kudos

Hi Mahboob,

I want to implement "Default year" as current year. Suppose I run the same report next year i.e. 2016, by default it should display 2016.

We don't want to pass value directly as we need to change it manually every year which is not a good idea.

Sandy

mhmohammed
Active Contributor
0 Kudos

Hey,

I used this blog to create and test what you want, I updated it a bit to get Current Year

Dave's Adventures in Business Intelligence: Dynamic Dates Part I: Yesterday and Today

  • Create a dimension object in the Universe called as Current Year. I've Sybase database, so I used select definition year(getdate()).

  • This object will give an error when you parse it, but that't not a problem. It'll work fine in the report.

  • Export the Universe.

  • In the report, create a filter as Year object = (from the drop down list) select object and then the Current Year object we created in the Universe.

Voila, you got it. Now the report is as if it has filter on Year = Current Year.

Thanks,

Mahboob Mohammed