2

I created an indexed view that joined a number of tables to get better performance, but when I use the indexed view, the performance is not better than before. When I survey the execution plan, I don't see any change between the view and the indexed view on these joined tables.

GarethD
  • 68,045
  • 10
  • 83
  • 123
mehdi lotfi
  • 11,194
  • 18
  • 82
  • 128

1 Answers1

6

If you are not using sql server enterprise edition (see feature Automatic use of indexed views by query optimizer), sql server query optimizer is not taking in account indexed views..

In other versions you can make sql server use it- With (NoExpand):

Select col1, col2, col3
From dbo.vw_MyView With (NoExpand)
bkwdesign
  • 1,953
  • 2
  • 28
  • 50
Jānis
  • 2,216
  • 1
  • 17
  • 27