Question: Use MySQL Server or My SQL Workbench to solve this problem. SHOW your run or output. Take a screenshot of your run or output. I

Use MySQL Server or My SQL Workbench to solve this problem. SHOW your run or output. Take a screenshot of your run or output. I will downvote any result that does not have a screenshot of the result or output. PLEASE provide a screenshot of the result or output that demonstrates your answer is correct ********* Here is the actual problem / question: Refer to the address, store, staff, and customer tables of the Sakila database. In this lab, these tables initially have the same
columns as in Sakila.
Implement a new strong entity phone, as shown in the following diagram:
The diagram uses Sakila naming conventions. Follow the Sakila conventions for your table and column names:
All lower case
Underscore separator between root and suffix
Foreign keys have the same name as referenced primary key
Implement the diagram in three steps:
Step 1. Remove the phone column from address. This column is replaced by the new strong entity.
Step 2. Implement the strong entity as a new phone table. Specify data types VarCHAR (12) for phone_type and integer for other
columns. Specify a suitable primary key and NOT NULL constraints according to the diagram.
Step 3. Implement the has relationships as foreign keys in customer, staff, and store. Specify UNIQUE constraints according to
the diagram. Specify SET NULL for delete rules and CASCADE for update rules, as follows:
ALTER TABLE customer
ADD FOREIGN KEY (phone_id) REFERENCES phone (phone_id) ON DELETE SET NULL ON UPDATE CASCADE;

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!