Monday, March 26, 2012

How to create indexes for views

Hi all,
It may be a stupid question but I'd be very happy if anyone could tell
my how to create an index on a view (creating an index on a table
works fine and is easy to do).
I have installed MS SQL Server 2000 running on a Windows 2000 machine.
Thanks in advance,
EdPlease read the page titled "Creating an Indexed View" for more information
on creating indexes on views. There are certain requirements to be met.
--
HTH,
Vyas, MVP (SQL Server)
http://vyaskn.tripod.com/
What hardware is your SQL Server running on?
http://vyaskn.tripod.com/poll.htm
"Eddie" <e.beyer@.gmx.net> wrote in message
news:29d450bb.0310020627.489ee1ae@.posting.google.com...
Hi all,
It may be a stupid question but I'd be very happy if anyone could tell
my how to create an index on a view (creating an index on a table
works fine and is easy to do).
I have installed MS SQL Server 2000 running on a Windows 2000 machine.
Thanks in advance,
Ed|||I'd start by typing 'indexed views' into the keywords to find section of the
index in Books Online. You'll find a lot of information that will help you
get started and things you need to be aware of. Let us know if you have any
specific questions after reading some of the basics... I hope this helps!
--
Brian Moran
Principal Mentor
Solid Quality Learning
SQL Server MVP
http://www.solidqualitylearning.com
"Eddie" <e.beyer@.gmx.net> wrote in message
news:29d450bb.0310020627.489ee1ae@.posting.google.com...
> Hi all,
> It may be a stupid question but I'd be very happy if anyone could tell
> my how to create an index on a view (creating an index on a table
> works fine and is easy to do).
> I have installed MS SQL Server 2000 running on a Windows 2000 machine.
>
> Thanks in advance,
> Ed|||Hi Ed
Indexed views work best when the underlying data is
infrequently updated. The maintenance of an indexed view
can be higher than the cost of maintaining a table index.
If the underlying data is updated frequently, then the
cost of maintaining the indexed view data may outweigh the
performance benefits of using the indexed view.
There is a lot more info. in Books Online that I would
consider reading.
>--Original Message--
>Hi all,
>It may be a stupid question but I'd be very happy if
anyone could tell
>my how to create an index on a view (creating an index on
a table
>works fine and is easy to do).
>I have installed MS SQL Server 2000 running on a Windows
2000 machine.
>
>Thanks in advance,
>Ed
>.
>

No comments:

Post a Comment