Answer Posted / sruthi
Index created on view is called as indexed view or
materialised view.
To create index on a view we should create a view
with "schemabinding"
eg:
create view v1 with schemabinding as
select empno,ename from dbo.emp
---
while creating view with schema binding refer to table by
default owner
---
now create index on that view
--
create clustered index i1 on v1(empno)
--
now this is called as indexed view
| Is This Answer Correct ? | 7 Yes | 1 No |
Post New Answer View All Answers
What are key constraints?
What is Replication?
What are the steps you must follow to hide sql server instances?
How do you start single user mode in clustered installations?
What is the default sql server instance name?
What is the difference between a view and a stored procedure?
When columns are added to existing tables, what do they initially contain?
What is #temp and @table variable in SQL server?
What is the query and subquery?
Explain what is dbcc?
What are the limitations/drawbacks or ssrs 2008 r2?
What is the difference between SQL notification and SQL invalidation?
What are logical database components? : SQL Server Architecture
Write a sql query to get zero records from a table having n number of records?
What is difference between primary key and foreign key?