282
Part II: Building Databases and Working with Data
FIGURE 11-3
The dependency chain for nested views is easily seen in the Object Dependencies dialog.
Here, the vEmployeeListDBA includes the nested view vEmployeeList, which in turn is based
on the Employee table, and so on.
Updating Through Views
One of the main complaints concerning views is that unless the view is a simple single table
view, it’s diffi cult to update the underlying data through the view. Although the SQL Server
Query Optimizer can update through some complex views, some hard-and-fast limitations exist.
Best Practice
Designing an application around updatable views is not recommended. Views are best used as an
abstraction layer for ad hoc queries and reports, not for power users to update data, and certainly not
for forms, websites, or client applications to update the database.
c11.indd 282c11.indd 282 7/30/2012 4:41:10 PM7/30/2012 4:41:10 PM
http://www.it-ebooks.info