From 0cfca4343d6ee0632ab98079bb2a5931a6c10b93 Mon Sep 17 00:00:00 2001 From: ddrechse Date: Wed, 31 Jul 2024 10:02:26 -0400 Subject: [PATCH] Add ALTER commands --- data-refactoring-advisor/hands-on-lab/virtualpdb/README.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/data-refactoring-advisor/hands-on-lab/virtualpdb/README.md b/data-refactoring-advisor/hands-on-lab/virtualpdb/README.md index abc7124fc..d06c4414e 100644 --- a/data-refactoring-advisor/hands-on-lab/virtualpdb/README.md +++ b/data-refactoring-advisor/hands-on-lab/virtualpdb/README.md @@ -84,6 +84,9 @@ GRANT SELECT ON GRANT SELECT ON College.department_courses_view to CourseCatalog ### then grant the role to the user coursedev GRANT CourseCatalogDeveloper TO coursedev; + +### Make the new role a default role +ALTER USER COURSEDEV DEFAULT ROLE ALL; ``` Now, the coursedev user can attach to the database and run queries on the view @@ -164,6 +167,9 @@ GRANT DELETE ON College.students_view to StudentDeveloper ### then grant the role to the user studentdev GRANT StudentDeveloper TO studentdev; + +### Make the new role a default role +ALTER USER STUDENTDEV DEFAULT ROLE ALL; ``` Now, the studentdev user can attach to the database and run CRUD operations on the view