May 2019
Intermediate to advanced
600 pages
20h 46m
English
There is yet another question posed by updatable views.
As an example, we shall use the cust_minor view we just defined, which does not allow you to perform insertions or updates so that the affected rows fall out of the view itself. For instance, consider this query:
UPDATE cust_minor SET age = 19 WHERE customerid = 123;
The preceding query will not affect any row because of the WHERE age < 18 conditions in the rule definition.
The CREATE VIEW statement has a WITH CHECK OPTION clause; if specified, any update that excludes any row from the view will fail.
If a view includes some updatable columns together with other non-updatable columns (for example expressions, literals, and so on), then updates are allowed if they only ...
Read now
Unlock full access