So I have been stuck whittling away some column labels in SSRS. Labels like “March 2009″. Using the expression editor you can input:

=MonthName(Month(Today())) & ” ” & Year(Today())

to get “March 2009″ so long as the system running reports server thinks today is in March of 2009.

For the month and year two months ago, I enter:

=MonthName(Month(DATEADD(“m”, -2, Today()))) & ” ” & Year(DATEADD(“m”, -2, Today()))

and get “January 2009″.

You get the idea. The biggest pain was determining the valid dateinterval for DateAdd. Why not just m, d, y like everything else?


No Comments on “Readable Expression Editor Dates in SSRS”

You can track this conversation through its atom feed.

No one has commented on this entry yet.

Leave a Reply

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>