This post originated from an RSS feed registered with .NET Buzz
by Peter van Ooijen.
Original Post: Disabling the SQL Reporting Services cache
Feed Title: Peter's Gekko
Feed URL: /error.htm?aspxerrorpath=/blogs/peter.van.ooijen/rss.aspx
Feed Description: My weblog cotains tips tricks and opinions on ASP.NET, tablet PC's and tech in general.
SQL Reporting Services keeps a copy of every report rendered in its cache. Of course this is quite a performance boost when a lot of users request the same report over and over again. But in our case this cache turned against us. We have an ASP.NET app whose reports are included in the app as a bunch of links to the reporting server. The page assembles the URL with the parameters (more on that later) and redirects the user to the report. Every time the user opened a report she was confronted with the previous version rendered. Based on the previous parameters. Clicking the the RS toolbar's refresh button (NOT the browser's refresh button) led to the intended report.
You can configure the caching of reports in great detail. It's under the execution tab in the report manager.
But there is a little quirk in this. Even when you set the report to Render this report with the most recent data, the user is (in our scenario) still confronted with a cached copy. This is either a bug or a misunderstanding between me and RS, I've seen others. What helped me here was using the rs:ClearSession parameter. In our app this is now the base URL for a report.