Considerations for updating data through views.
You cannot update views defined with the distinct clause.
create view stores_cal as select * from stores where state = "CA" with check option
update stores_cal set state = "WA" where store_id = "7066"
If a view is created with check option, all views derived from the base view must satisfy the view’s selection criteria. Each row updated through a derived view must remain visible through the base view.
create view stores_cal30 as select * from stores_cal where payterms = "Net 30"
Because stores_cal was created with check option, all rows updated through stores_cal30 must remain visible through stores_cal. Any row that changes state to a value other than “CA” is rejected.
update stores_cal30 set payterms = "Net 60" where stor_id = "7067"
The view has no with check option clause, and
All columns being updated belong to the same base table.
update statements are allowed on join views that contain a with check option clause. The update fails if any of the affected columns appear in the where clause in an expression that includes columns from more than one table.
If you update a row through a join view, all affected columns must belong to the same base table.