Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2008 Forums
 Analysis Server and Reporting Services (2008)
 Currentmonth -1 in SSRS 2008

Author  Topic 

sathyarangaraj
Starting Member

11 Posts

Posted - 2012-11-02 : 04:54:53
Hi All,

How to get the currentmonth-1. I have Month in int format 201108, 201109 in table. But when the user selects 201108, it should pickup 201107.

Please help me to do this. Thank you all

sunitabeck
Master Smack Fu Yak Hacker

5155 Posts

Posted - 2012-11-02 : 08:35:22
What format is your underlying data? If it is a date then you can do something like this:
=Format(dateadd("m",-1,Fields!YourDateField.Value),"yyyyMM")
Here, YourDateField is the parameter or column that has the date field.
Go to Top of Page
   

- Advertisement -