Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Use SQL Developer to execute SQL statements to complete the following tasks: 1. Create an index on the employee Last Name column of the employee

Use SQL Developer to execute SQL statements to complete the following tasks:

1. Create an index on the employee Last Name column of the employee table.

2. Create an index on the combination of Last Name and First Name columns of the employee table.

3. Create a view Emp_Pay_View containing the employee ID, the employee Last Name, the warehouse number, and Pay Rate. Ensure that the view allows users only to view, and not to update, the data. Use the view in a select command to display all data.

4. Create a view Order_Product containing the Order ID, Order Date, Product ID, Product Name columns from the Order and Product tables. Use the view in a select command to list the Order ID, Order Date, Product ID, and Product Name for all Orders that have been shipped but not delivered.

For the following commands you must be logged in as user system. You will need to do some research on the commands CREATE USER; GRANT CREATE SESSION; GRANT CREATE..; GRANT ALTER ., GRANT SELECT.; REVOKE ; and EXECUTE ..

5. Create two database users:

The first is a concatenation of your first and last name (e.g., johndoe).

The second is a concatenation of your Instructors first and last name (e.g., sallysmith)

6. Assign the two users privileges to connect to your database instance.

7. Assign the user with your first and last name all privileges to the Order table.

8. Assign the user with your Instructors first and last name the privilege to select data from the employees table.

9. Assign the user with your Instructors first and last name the privilege to execute any procedure.

10. Take away your privilege to execute any SQL commands on the Order table.

The screen shots must be numbered to correspond with the problem numbers in the Lab.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Databases questions