Updating views in sql server what is silent dating
Keep the following rule in mind whenever you consider updating views: You can’t update a column in a view unless it corresponds to a column in an underlying base table.Performs insert, update, or delete operations on a target table based on the results of a join with a source table.You'll have to test each specific case to be sure, though!
If I am running a transaction that updates some dependent tables, is there a performance impact while the indexed views are updated? This is a qustion for Kalen, since she does internals.
you cannot update a union CERTAINLY NOT WHEN DIFFERENT TABLES ARE INVOLVED (unless of course you have an instead of trigger on it...) you need to specify the updates to the actual tables involved...
you could of course update via insert into table select ,,,, from myview Lowfatspread: I am able to update the identical view2 on the server where the stored proc is running from, but not able to update view2 on the remote server.
For example, inserting a row if it does not exist, or updating the row if it does match.
When simply updating one table based on the rows of another table, improved performance and scalability can be achieved with basic INSERT, UPDATE, and DELETE statements.
If it is a narrow view (few columns with few bytes), then the performance hit would be comparable with the addition of a 'regular' index to the base table.