Reputation: 45
I have created a ssrs report and this report display last 12 months data. I have 2 parameters startDate and Enddate. The End date is always the current month and I want the start date to be the last 12 months. For example if my (End Date) current month is JAN 2018. I want my start date to be Feb 2017. I have below expression but this give me Jan 2017 date for my start date.
=DateAdd("M", -12,Today())
Upvotes: 2
Views: 6252
Reputation: 3195
Try this expression for the start date parameter default value.
=DateAdd(DateInterval.Year, -1, DateAdd(DateInterval.Month, 1, Parameters!EndDate.Value))
Here's what the parameter values would equal:
Upvotes: 1