WHENEVER SQLERROR EXIT SQL.SQLCODE

CREATE END USER emma IDENTIFIED BY "Welcome1_DDS!";
CREATE END USER marvin IDENTIFIED BY "Welcome1_DDS!";
CREATE END USER victoria IDENTIFIED BY "Welcome1_DDS!";

CREATE DATA ROLE employee_role;
CREATE DATA ROLE manager_role;
CREATE DATA ROLE hr_role;

CREATE ROLE pii_session_role;
GRANT CREATE SESSION TO pii_session_role;
GRANT pii_session_role TO employee_role;
GRANT pii_session_role TO manager_role;
GRANT pii_session_role TO hr_role;

GRANT DATA ROLE employee_role TO emma;
GRANT DATA ROLE employee_role TO marvin;
GRANT DATA ROLE manager_role TO marvin;
GRANT DATA ROLE hr_role TO victoria;
