View the step-by-step solution to:

SQL Assignment COMP2231/COMP8231 E. Use MySQL to make the following changes to the Alexamara Marina Group database. Dene a view named LARGE SLIP. It...

Alexamara marina group exercise chapter 6
The question has attached in the file.
SQL Assignment COMP2231 / COMP8231 E. Use MySQL to make the following changes to the Alexamara Marina Group database. 1. Define a view named LARGE SLIP. It consists of the marina number, slip number, rental fee, boat name, and owner number for every slip whose length is 40 feet. a. Write and execute the CREATE VIEW command to create the LARGE SLIP view. b. Write and execute the command to retrieve the marina number, slip number, rental fee, and boat name for every slip with a rental fee of $3800 or more. c. Write and execute the query that the DBMS actually executes. d. Does updating the database through this view create any problems? If so, what are they? If not, why not? 2. Define a view named RAY 4025. It consists of the marina number, slip number, length, rental fee, boat name, and owner’s last names for every slip in which the baot type is Ray 4025. a. Write and execute the CREATE VIEW command to create the RAY 4025 view. b. Write and execute the command to retrieve the marina number, slip number, rental fee, boat name, and owner’s last name for every slip in the RAY 4025 view with a rental fee of less than $4000. c. Write and execute the query that the DBMS actually executes. d. Does updating the database through this view create any problems? If so, what are they? If not, why not? 3. Define a view named SLIP FEES. It consists of two columns: the first is the the slip length, and the second is the average fee for all slips in the MARINA SLIP table that have that length. Use AVERAGE FEE as the name for the average fee. Group and order the rows by slip length. a. Write and execute the CREATE VIEW command to create the SLIP FEES view. b. Write and execute the command to retrieve the slip length and average fee for each length for which the average fee is less than $3500. c. Write and execute the query that the DBMS actually executes. d. Does updating the database through this view create any problems? If so, what are they? If not, why not? 4. Write, but do not execute, the commands to grant the following privileges. a. User Oliver must be able to retrieve data from the MARINA SLIP table. b. Users Crandall and Perez must be able to add new owners and slips to the database. c. Users Johnson and Klein must be able to change the rental fee of any slip. d. All users must be able to retrieve the length, boat name, an owner number of every slip. e. User Klein must be able to add and delete service categories. f. User Adams must be able to create an index on the SERVICE REQUEST table. g. Users Adams and Klein must be able to change the structure of the MARINA SLIP table. h. User Klein must have all privileges on the MARINA table. DM / DM GE SQL Assignment, revised 2010, CHM School of Computer Science, Engineering & Mathematics, Flinders University 7
Background image of page 1

Recently Asked Questions

Why Join Course Hero?

Course Hero has all the homework and study help you need to succeed! We’ve got course-specific notes, study guides, and practice tests along with expert tutors.

-

Educational Resources
  • -

    Study Documents

    Find the best study resources around, tagged to your specific courses. Share your own to gain free Course Hero access.

    Browse Documents
  • -

    Question & Answers

    Get one-on-one homework help from our expert tutors—available online 24/7. Ask your own questions or browse existing Q&A threads. Satisfaction guaranteed!

    Ask a Question