SQL Lab13.docx - Lab 13 To perform the following assignments refer to the tables in the JustLee Books database 1 Create a view that lists the name and

SQL Lab13.docx - Lab 13 To perform the following...

This preview shows page 1 - 2 out of 2 pages.

Lab 13 To perform the following assignments, refer to the tables in the JustLee Books database. 1. Create a view that lists the name and phone number of the contact person at each publisher. Don’t include the publisher’s ID in the view. Name the view CONTACT. 2. Change the CONTACT view so that no users can accidentally perform DML operations on the view. CREATE OR REPLACE VIEW CONTACT AS SELECT name, phone FROM publisher WITH READ ONLY 3. Create a view called HOMEWORK13 that includes the columns named Col1 and Col2 from the FIRSTATTEMPT table. Make sure the view is created even if the FIRSTATTEMPT table doesn’t exist. CREATE VIEW homework13 AS SELECT Col1, Col2 FROM firstattempt 4. Attempt to view the structure of the HOMEWORK13 view. DESC homework13
Image of page 1
Image of page 2

You've reached the end of your free preview.

Want to read both pages?

  • Summer '16
  • The Table, Prime number, Articles with example SQL code

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture