Oracle Database SQL — Question 108
Which two statements are true about views? (Choose two.)
Answer options
- A. The WITH CHECK clause prevents certain rows from being updated or inserted in the underlying table through the view.
- B. The WITH CHECK clause prevents certain rows from being displayed when querying the view.
- C. Views can be indexed.
- D. Views can be updated without the need to re-grant privileges on the view.
- E. Tables in the defining query of a view must always exist in order to create the view.
Correct answer: A, D
Explanation
The correct answer is A because the WITH CHECK clause indeed restricts updates and inserts to certain rows in the underlying table through the view. Option D is correct since views can be updated without re-granting privileges. Option B is incorrect as the WITH CHECK clause does not affect row visibility in queries. Option C is wrong because views cannot be indexed directly, and option E is misleading since while the underlying tables must exist, they do not need to be present at the moment of view creation if the view's definition is valid.