Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
AskSQLTeam
Ask SQLTeam Question
0 Posts |
Posted - 2006-03-16 : 09:17:08
|
| Lalitha writes "Can I use DML statements against indexed views?If yes how it works internally, means will the pages gets locked during update and inserts and when the base tables get reflected of these modified data?" |
|
|
druer
Constraint Violating Yak Guru
314 Posts |
Posted - 2006-03-17 : 14:23:47
|
| I'm interested to see myself how Indexed Views work internally so I can't wait to see the input on that. I always understood Views to be nothing more than a way to have pre-compiled query strings together, and that the "code" in them was simply added to the strings that used them, so how an index is maintained on data that doesn't exist is interesting. My guess has been that they create another index just like if you had created it for the table(s) themselves and if you update the underlying table data then the view's index is also modified as a dependency. But I'm looking forward to the "real" DBA's answers.In terms of whent the base tables get modified, as far as I can tell(know) they get modified immediately when you invoke the command Update/Delete/Insert command. |
 |
|
|
|
|
|