Monday, 13 January 2014

How to set first day of current month as the default date in SSRS report (SQL 2008 R2)


First you need to create a parameter to set the date. In my project I have two parameters as @startDate and @endDate. I need to set the @startDate as the first day of current month and @endDate as today as the default values. Here are the steps to do it.

1.       Go to @startDate parameter properties - > Default Values -> Select Specify Values -> =DateSerial(Year(Now), Month(Now), 1)

 


 2.       To set the current date for @endDate follow the same steps as above and use following expression.  =Today()

 

No comments:

Post a Comment