O'Reilly logo

Programming Microsoft® ADO.NET 2.0 Core Reference, 2nd Edition by David Sceppa

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Caching Data Between Roundtrips

So now you know how to display data on a Web page by using the SqlDataSource and bound controls such as GridView and DetailsView. What if you don’t want to execute the same queries every time someone hits your Web server? Maybe you want to cache the results of a process-intensive query. Maybe you want to store the contents of the user’s shopping cart.

ASP.NET offers many caching features that let you control how you maintain data for your application or for each separate session. The features themselves are very straightforward. However, there’s no single universal right or wrong way to cache data. Relying on a particular caching feature in one application might improve performance, whereas using the same feature ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required