Monday, 13 January 2014

How to format the date format in SSRS reports (SQL 2008 R2)


Date can be format to what to different formats. Below I talk about a common requirement to format date/time. In my report I have Open and Closed dates as mm/dd/yyyyy hh:mm:ss (am/pm). Here I’m going to change the format.
I set the expression as below:

=Format(Fields!clo_dte.Value,"dd/MM/yyyy hh:mm:ss tt")

You may have noted that only MM is in upper case. (month)
If you set the HH in upper case then it use 24 hr time format. (hour)

No comments:

Post a Comment