I am going to design a Data Warehouse and I heard about materialized views. Actually I want to create a view and it should update automatically when base tables are changed. Can anyone explain with a query example?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
They’re called indexed views in SQL Server – read these white papers for more background:
Basically, all you need to do is:
and you’re done!
The tricky part is: the view has to satisfy quite a number of constraints and limitations – those are outlined in the white paper. If you do this, that’s all there is. The view is being updated automatically, no maintenance needed.
Additional resources: