Indexed Views

SQL Server 2000 introduced indexed views. They provide you with greatly improved performance by allowing you to create a unique clustered index for a view. Here's the reason why. SQL Server does not store the result set of a standard view in the database. Each time a query references the view, SQL Server dynamically creates the result set. The overhead of building the result set can be substantial, particularly for complex views. You can greatly improve performance by creating a unique clustered index for the view. When you create a unique clustered index, SQL Server stores the data that exists at the time you create the view. SQL Server then reflects all modifications to table data within the stored view. This improves the efficiency ...

Get Alison Balter's Mastering Access 2002 Enterprise Development now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.