Sql server indexed view

Posted by Jose on Stack Overflow See other posts from Stack Overflow or by Jose
Published on 2010-05-07T14:20:34Z Indexed on 2010/05/07 14:28 UTC
Read the original article Hit count: 321

OK, I'm confused about sql server indexed views(using 2008)

I've got an indexed view called

AssignmentDetail

when I look at the execution plan for

select * from AssignmentDetail

it shows the execution plan of all the underlying indexes of all the other tables that the indexed view is supposed to abstract away.

I would think that the execution plan woul simply be an clustered index scan of PK_AssignmentDetail(the name of the clustered index for my view) but it doesn't.

There seems to be no performance gain with this indexed view what am I supposed to do? Should I also create a non-clustered index with all of the columns so that it doesn't have to hit all the other indexes?

Any insight would be greatly appreciated

© Stack Overflow or respective owner

Related posts about sql-server

Related posts about sql-server-2008