Home / chathollandcam / Sql updating a view

Sql updating a view

All operations on a SQL Server table result in another table.

This is a requirement of the relational model and is referred to as relational closure.

Almost any SQL that can be issued natively can be coded into a view; there are exceptions, however.

sql updating a view-61sql updating a view-22

This causes the advantages of views to become muddled and misunderstood.

No physical structure is required of a view; it is a representation of data that is stored in other tables. When modifying data through a view (that is, using INSERT or UPDATE statements) certain limitations exist depending upon the type of view.

The data "in the view" is not stored anywhere and only physically exists in the underlying tables. Views that access multiple tables can only modify one of the tables in the view.

They are wonderful tools that ease data access and system development when used prudently.

Furthermore, views are simple to create and implement.


  1. Why are people advised not to update through views. There is no performance disadvantage to Updating these Views as SQL Server will just generate a.

  2. Inside the view you show ClaimStatusName. So you update name inside dimClaimStatus table. This is the reason for 1 rows affected. When you refresh the view you see new string inside multiple rows inside the view.

  3. A view is only a logical entity it does not exists on the database, view are used to view or fetch related data from more than one table, so there is nothing like updating a view because to update a view you need to update data of underlaying tables can some what compare joins with view as both do not resides in the database.

  4. Sep 30, 2015. I was recently asked how to update views. Specifically the question was about using triggers to update a view. So updating a simple view is easy enough. Per BOL Updatable Views You can modify the data of an underlying base table through a view, as long as the following conditions are true Any.

Leave a Reply

Your email address will not be published. Required fields are marked *