Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Consider the database below. Where, the primary keys are underlined and the foreign key (FK) relationships are: PROJECT.Dnum is FK ref. DEPARTMENT.Dnumber; PROJECT.Plocation is FK

image text in transcribed

image text in transcribed

image text in transcribed

image text in transcribed

image text in transcribed

Consider the database below. Where, the primary keys are underlined and the foreign key (FK) relationships are: PROJECT.Dnum is FK ref. DEPARTMENT.Dnumber; PROJECT.Plocation is FK ref. DEPT_LOCATIONS.Dlocation; DEPT_LOCATIONS.Dnumber is FK ref. DEPARTMENT.Dnumber; DEPARTMENT.Mgr_ssn is FK ref. EMPLOYEE.Ssn; EMPLOYEE.Super_ssn is FK ref. EMPLOYEE.Ssn; EMPLOYEE.Dno is FK ref. DEPARTMENT.Dnumber. Suppose each of the following update operations is applied directly to this database: Dno B 5 5 4 4 5 5 4 1 EMPLOYEE Frame Minit Lname San Bdate Address Sex Salary Super_san John B Smith 123456789 1965-01-09 731 Fondren, Houston, TX M 30000 333445555 Franklin T Wong 333445555 1955-12-08 638 Voss, Houston, TX M 40000 888665555 Alicia J Zelaya 999887777 1968-01-19 3321 Castle, Spring, TX F 25000 987654321 Jennifer S Wallace 987654321 1941-06-20 291 Berry, Bellaire, TX F43000 888665555 Ramesh K Narayan 666884444 1962-09-15 975 Fire Oak, Humble, TX M 38000 333445555 Joyce English 453453453 1972-07-31 5631 Rice, Houston, TX F 25000 333445555 Ahmad V Jabbar 987987987 1969-03-29 980 Dallas, Houston, TX M 25000 987654321 James E Borg 888665555 1937-11-10 450 Stone, Houston, TX M 55000 NULL PROJECT Pname Pnumber Plocation Dnum DEPT_LOCATIONS ProductX 1 Bellaire 5 Dnumber Dlocation ProductY 2 Sugarland 5 1 Houston Productz 3 Houston 5 4 Stafford Computerization 10 Stafford 4 5 Bellaire Reorganization 20 Houston 1 5 Sugarland Newbenefits 30 Stafford 4 Houston DEPARTMENT Dname Dnumber Mgr_ssn Mgr_start_date Research 5 333445555 1988-05-22 Administration 4 987654321 1995-01-01 Headquarters 1 888665555 1981-06-19 UN U UN Choose the correct statements regarding the integrity constraints (i.e. key constraints, entity and referential integrity constraint) of the following operation when applied to the database on the left: UPDATE EMPLOYEE SET Fname = 'John', Minit = 'B', Lname = 'Smith' WHERE Ssn = '987654321'; Select one or more alternatives: It violates referential integrity. It violates the key constraint. No constraint violations. It violates entity integrity Choose the correct statements regarding the integrity constraints (i.e. key constraints, entity and referential integrity constraint) of the following operation when applied on the database shown to the left. DELETE FROM EMPLOYEE WHERE EMPLOYEE.SSN = '888665555 Select one or more alternatives: It violates referential integrity because of the foreign key from EMPLOYEE to EMPLOYEE It violates entity integrity constraint because Super_ssn is NULL for the employee with Ssn 888665555. It violates the key constraint because the primary key of the deleted employee is equal to Mgr_ssn for the department with Dnumber 1. It violates referential integrity because of the foreign key from DEPARTMENT to EMPLOYEE U No constraint violations. It violates the entity integrity constraint because we are deleting based on a primary key

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

Recommended Textbook for

Database Design And SQL For DB2

Authors: James Cooper

1st Edition

1583473572, 978-1583473573

More Books

Students also viewed these Databases questions