- All objects of the specified object type in the system
- All objects of the specified object type in the database
- Specific object
VIEW privilege for all views (where a view is the object type) in a specified database.
Grant Privileges
This workflow creates a group and grants theVIEW privilege to all views and the ability to read the views in the database to the group.
1
Create the
view_analyst group. You can see the created group using the sys.groups system catalog table.SQL
2
Grant the
VIEW privilege for views on the test database to the view_analyst group.SQL
3
Grant the
SELECT privilege on the database to the group.SQL
4
View the granted privileges using the Output
sys.privileges system catalog table. The Ocient System grants the USE privilege on the database implicitly.SQL
Text
Verify Privileges
This workflow creates a user, assigns this user to the created group, and creates a view with generated data. The workflow shows the information that the user has access to in the database based on the granted privileges.1
Create the
test_user user.SQL
2
Add the user to the
view_analyst group.SQL
3
Create the
view view that selects five generated rows.SQL
4
Connect to the database at the
10.10.1.1 IP address with port number 4050 as the test_user user.Shell
5
View the privileges of the user using the Output
sys.privileges system catalog table. This user has no privileges of their own.SQL
Text
6
See the metadata for views that the user has access to within this database. The user has access to the Output
test view only.SQL
Text
7
Verify that the user can select the data in the Output
view view.SQL
Text

