Question: Write an insert statement to: Insert into the PROFESSOR table the professor's first name and last name James McCall, who has office number 306 in

  1. Write an insert statement to:
    1. Insert into the PROFESSOR table the professor's first name and last name James McCall, who has office number 306 in Adams building. The professor's phone number is 713-300-2010.
    2. Imagine that there is an archive table called COLLEGE_ARC. Insert all data of the COLLEGE_ARC into the COLLEGE table. Both tables have the same fields.

  1. Write data-retrieving statements for each of the following:
    1. Write an ALTER statement to add the column Rank to the PROFESSOR table. Assume that Rank is not required.
    2. Write an ALTER statement to make Phone an alternate key in COLLEGE.
    3. Write an UPDATE statement to change the city of a student with student number 101102 to 'Houston'.
    4. Write an UPDATE statement to change the phone number of a student with ID 107111 to '713-543-0011' and the state to 'TX'.
    5. Write a statement to delete all data for professor 'James McCall.'
    6. Delete all data in the COLLEGE table but keep the table structure.
    7. Write a view to select the dean's first and last name whose appointment title is "Advisor"

  1. Advanced DML.
    1. Create a user-defined function named FUNC_APPOINTMENT that combines the Title and Term of the APPOINTMENT table into a concatenated name field.
    2. Create a stored procedure that selects the student's first and last names with a certain (variable) city and state.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!