QuercusPlus System Administrator’s Guide to Application Roles<>

Setting up users

QuercusPlus and Oracle

Before a person can become a QuercusPlus user, he or she must first be set up as an user for the Oracle QuercusPlus database.

User set up methods

You can set up users using either:

Oracle Enterprise Manager

SQL Plus command line utility

The Oracle Enterprise Manager is the more user-friendly method. It is also the best choice if you want to check all the settings that relate to an individual user.

The SQL Plus command line utility is faster for bulk operations. If you plan to add many users at the same time, and these users fall into groups sharing the same access requirements then consider using SQL Plus rather than Enterprise Manager.

Setting up users using Oracle Enterprise Manager

The Enterprise Manager

The Oracle Enterprise Manager is a database administration console which allows you to manage all aspects of your database set up as well as providing a range of diagnostic utilities and performance indicators. It has a standard Windows-style user-interface. It provides a graphical alternative to the SQL Plus utility for a variety of database administrative operations.

Note: The user interface in Oracle Enterprise Manager differs slightly from version to version.

The screenshots below are from Oracle 11g Release 1.

To create a user using Enterprise Manager

1Open the Enterprise Manager and and connect to the Quercus database.

2Click the Sever tab.

3Under Security choose Users.

A list of users opens.

4Click the Create button at the top right of the list.

The Users screen opens on the General tab.

5Complete the screen by entering the new user’s details.

6Click OK to create the user.

You are returned to the list screen of users. A message appears confirming that the user has been created and the user appears in the list.

To assign roles to a user using Enterprise Manager

1Select a user in the user list and click Edit.

The user’s profile opens.

2Click the Roles tab to view a list of the user’s current roles.

3To edit the user’s roles click the Edit List tab.

The Modify Roles screen opens allowing you to select which roles are assigned to the user.

Use the Move and Remove controls to choose which roles you want to assign to the user.

4Press OK when you have finished selecting roles.

You are return to the Roles tab.

5Click the Apply button to apply the selected roles to the user.

A message appears confirming that the user’s record has been modified.

Setting up users using SQL Plus

The SQL Plus utility

The SQL Plus utility is a command-line utility similar to the command prompt in Windows or the terminal utility in Unix or Linux systems.

Note the following:

Commands must be ended by a semi-colon ( ; )

You can prepare a command by typing it in a text editor such as Windows Notepad and then pasting it into the SQL Plus window using the Edit > Paste command from the SQL Plus menu.

You can edit and modify the previous command by typing ‘ed’ after the command prompt. This opens the buffered command in a text editor.

Modify the command as required and then save the modified buffer when you exit the text editor. Then type a forward slash ( / ) to execute the modified command.

To create a user using SQL Plus

1Open the SQL command-line utility and connect to the Quercus database.

Enter:

create user [username]
identified by [password]
default tablespace [default tablespace]
quota [quota] on [default tablespace]
temporary tablespace [temporary tablespace];

Example:

create user mhope
identified by hu42STew
default tablespace quercus_data
quota 10m on quercus_data
temporary tablespace temp;

2Press Return.

If the command has executed successfully you will receive a ‘User Created’ message.

To assign roles to users using SQL Plus

1Enter:

grant [role 1], [role 2], … [role n] to [user 1], [user 2] … [user n];
commit;

Examples:

grant quercus_user to mhope;
grant admissions_role, course_manager_admin to dbradshaw, msmith;

2Press Return.

To revoke roles from users using SQL Plus

1Enter:

revoke [role 1], [role 2], … [role n] from [user 1], [user 2] … [user n];

Examples:

revoke quercus_user from mhope;
revoke admissions_role, course_manager_admin from dbradshaw, msmith;

2Press Return.

To delete a user using SQL Plus

1Enter:

drop user [username];

Example

drop user mhope;