Question
A database administrator needs to provide access to data from two different tables to multiple group users in order to facilitate ongoing reporting. However, some columns in each table are restricted, and users should not be able to see the values in these columns.
Which of the following is the best action for the administrator to take?
- A. Create a stored procedure.
- B. Create a view. Correct
- C. Create a .csv export.
- D. Create a trigger.
Explanation
A view can join the two tables and expose only the permitted columns, and users can be granted access to the view without access to the underlying tables, so it supports ongoing reporting while hiding restricted columns. A stored procedure is suited to parameterized operations rather than reusable reporting access, a .csv export is a static copy that goes stale and is hard to secure, and a trigger runs in response to data changes and does not control what users can read.