Supposed that each of the following Update operations is applied directly to the database state shown...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
Supposed that each of the following Update operations is applied directly to the database state shown in the Figure 3.6. Discuss all integrity constraints violated by each operation, if any, and the different ways of enforcing these constraints. Please work on only problems b, c, f, g, and i. a. Insert <Robert', 'F', 'Scott', '943775543', '1972-06-21', '2365 Newcastle Rd, Bellaire, TX, M, 58000, '888665555', 1> into EMPLOYEE. b. Insert <ProductA', 4, 'Bellaire', 2> into PROJECT. c. Insert <Production', 4, '943775543', '2007-10-01'> into DEPARTMENT. d. Insert <677678989', NULL, '40.0'> into WORKS_ON. e. Insert <453453453', 'John', 'M', '1990-12-12', 'spouse'> into DEPENDENT. f. Delete the WORKS ON tuples with Essn = '333445555'. g. Delete the EMPLOYEE tuple with Ssn = '987654321'. h. Delete the PROJECT tuple with Pname = 'ProductX'. i. Modify the Mgr_ssn and Mgr_start_date of the DEPARTMENT tuple with Dnumber = 5 to $123456789' and '2007-10-01', respectively. j. Modify the Super_ssn attribute of the EMPLOYEE tuple with Ssn = $999887777' to '943775543'. k. Modify the Hours attribute of the WORKS ON tuple with Essn = $999887777' and Pno = 10 to '5.0'. 2. Consider the following relations for a database that keeps track of bank customers and their accounts: BRANCH (Branch Name, Assets, Bcity) CUSTOMER (CustName, SSN, Street, City) DEPOSIT (Branch_name, AcctNo, CustName, Balance) LOAN (Branch_name, LoanNo, CustName, Amount) Specify the foreign keys for this schema. EMPLOYEE Fname Minit Lname Ssn Bdate DEPARTMENT Dname Dnumber Mgr_ssn Mgr_start_date DEPT LOCATIONS Dnumber Dlocation PROJECT Pname Pnumber Plocation Dnum Address Sex Salary WORKS ON Essn Pno Hours DEPENDENT Essn Dependent_name Sex Bdate Relationship Super_ssn Dno Figure 3.7 Referential integrity constraints displayed on the COMPANY relational database schema. Figure 3.6 One possible database state for the COMPANY relational database schema. EMPLOYEE Fname Minit Lname Ssn Bdate Address John B Smith 123456789 1965-01-09 731 Fondren, Houston, TX Franklin T Wong 333445555 1955-12-08 638 Voss, Houston, TX Alicia J Zelaya 999887777 1968-01-19 3321 Castle, Spring, TX Jennifer S Wallace 987654321 1941-06-20 291 Berry, Bellaire, TX Ramesh K Narayan 666884444 1962-09-15 975 Fire Oak, Humble, TX Joyce A English 453453453 1972-07-31 5631 Rice, Houston, TX Ahmad V Jabbar 987987987 1969-03-29 980 Dallas, Houston, TX James E Borg 888665555 1937-11-10 450 Stone, Houston, TX DEPARTMENT Dname Research Administration Headquarters Dnumber 5 4 1 Mgr_ssn 333445555 987654321 888665555 Mgr_start_date 1988-05-22 1995-01-01 1981-06-19 Sex Salary Super_ssn Dno M 30000 333445555 M 40000 888665555 F 25000 987654321 4 43000 888665555 F 4 38000 333445555 5 25000 333445555 5 25000 987654321 4 55000 NULL 1 M F M M DEPT_LOCATIONS Dnumber 1 4 5 10 5 5 55 01 Dlocation Houston Stafford Bellaire Sugarland Houston Figure 3.6 One possible database state for the COMPANY relational database schema WORKS ON Essn 123456789 123456789 666884444 453453453 453453453 333445555 333445555 333445555 333445555 999887777 999887777 987987987 987987987 987654321 987654321 888665555 Pno Hours 1 32.5 2 7.5 3 40.0 1 20.0 2 20.0 2 10.0 10.0 10.0 10.0 30 30.0 10 10.0 10 35.0 5.0 20.0 15.0 NULL 3 10 20 30 30 20 20 DEPENDENT Essn 333445555 333445555 333445555 987654321 123456789 123456789 123456789 PROJECT Pname ProductX ProductY ProductZ Computerization Reorganization Newbenefits Dependent_name Alice Theodore Joy Abner Michael Alice Elizabeth Pnumber 1 2 3 10 20 30 Sex F M F M Plocation Bellaire Sugarland Houston Stafford Houston Stafford Dnum 5 5 5 4 1 4 Bdate Relationship 1986-04-05 Daughter 1983-10-25 Son 1958-05-03 Spouse 1942-02-28 Spouse M 1988-01-04 Son F 1988-12-30 Daughter F 1967-05-05 Spouse Supposed that each of the following Update operations is applied directly to the database state shown in the Figure 3.6. Discuss all integrity constraints violated by each operation, if any, and the different ways of enforcing these constraints. Please work on only problems b, c, f, g, and i. a. Insert <Robert', 'F', 'Scott', '943775543', '1972-06-21', '2365 Newcastle Rd, Bellaire, TX, M, 58000, '888665555', 1> into EMPLOYEE. b. Insert <ProductA', 4, 'Bellaire', 2> into PROJECT. c. Insert <Production', 4, '943775543', '2007-10-01'> into DEPARTMENT. d. Insert <677678989', NULL, '40.0'> into WORKS_ON. e. Insert <453453453', 'John', 'M', '1990-12-12', 'spouse'> into DEPENDENT. f. Delete the WORKS ON tuples with Essn = '333445555'. g. Delete the EMPLOYEE tuple with Ssn = '987654321'. h. Delete the PROJECT tuple with Pname = 'ProductX'. i. Modify the Mgr_ssn and Mgr_start_date of the DEPARTMENT tuple with Dnumber = 5 to $123456789' and '2007-10-01', respectively. j. Modify the Super_ssn attribute of the EMPLOYEE tuple with Ssn = $999887777' to '943775543'. k. Modify the Hours attribute of the WORKS ON tuple with Essn = $999887777' and Pno = 10 to '5.0'. 2. Consider the following relations for a database that keeps track of bank customers and their accounts: BRANCH (Branch Name, Assets, Bcity) CUSTOMER (CustName, SSN, Street, City) DEPOSIT (Branch_name, AcctNo, CustName, Balance) LOAN (Branch_name, LoanNo, CustName, Amount) Specify the foreign keys for this schema. EMPLOYEE Fname Minit Lname Ssn Bdate DEPARTMENT Dname Dnumber Mgr_ssn Mgr_start_date DEPT LOCATIONS Dnumber Dlocation PROJECT Pname Pnumber Plocation Dnum Address Sex Salary WORKS ON Essn Pno Hours DEPENDENT Essn Dependent_name Sex Bdate Relationship Super_ssn Dno Figure 3.7 Referential integrity constraints displayed on the COMPANY relational database schema. Figure 3.6 One possible database state for the COMPANY relational database schema. EMPLOYEE Fname Minit Lname Ssn Bdate Address John B Smith 123456789 1965-01-09 731 Fondren, Houston, TX Franklin T Wong 333445555 1955-12-08 638 Voss, Houston, TX Alicia J Zelaya 999887777 1968-01-19 3321 Castle, Spring, TX Jennifer S Wallace 987654321 1941-06-20 291 Berry, Bellaire, TX Ramesh K Narayan 666884444 1962-09-15 975 Fire Oak, Humble, TX Joyce A English 453453453 1972-07-31 5631 Rice, Houston, TX Ahmad V Jabbar 987987987 1969-03-29 980 Dallas, Houston, TX James E Borg 888665555 1937-11-10 450 Stone, Houston, TX DEPARTMENT Dname Research Administration Headquarters Dnumber 5 4 1 Mgr_ssn 333445555 987654321 888665555 Mgr_start_date 1988-05-22 1995-01-01 1981-06-19 Sex Salary Super_ssn Dno M 30000 333445555 M 40000 888665555 F 25000 987654321 4 43000 888665555 F 4 38000 333445555 5 25000 333445555 5 25000 987654321 4 55000 NULL 1 M F M M DEPT_LOCATIONS Dnumber 1 4 5 10 5 5 55 01 Dlocation Houston Stafford Bellaire Sugarland Houston Figure 3.6 One possible database state for the COMPANY relational database schema WORKS ON Essn 123456789 123456789 666884444 453453453 453453453 333445555 333445555 333445555 333445555 999887777 999887777 987987987 987987987 987654321 987654321 888665555 Pno Hours 1 32.5 2 7.5 3 40.0 1 20.0 2 20.0 2 10.0 10.0 10.0 10.0 30 30.0 10 10.0 10 35.0 5.0 20.0 15.0 NULL 3 10 20 30 30 20 20 DEPENDENT Essn 333445555 333445555 333445555 987654321 123456789 123456789 123456789 PROJECT Pname ProductX ProductY ProductZ Computerization Reorganization Newbenefits Dependent_name Alice Theodore Joy Abner Michael Alice Elizabeth Pnumber 1 2 3 10 20 30 Sex F M F M Plocation Bellaire Sugarland Houston Stafford Houston Stafford Dnum 5 5 5 4 1 4 Bdate Relationship 1986-04-05 Daughter 1983-10-25 Son 1958-05-03 Spouse 1942-02-28 Spouse M 1988-01-04 Son F 1988-12-30 Daughter F 1967-05-05 Spouse
Expert Answer:
Answer rating: 100% (QA)
b Insert into PROJECT Integrity Constraints Violated Referential Integrity The foreign key constraint between PROJECT and DEPARTMENT is violated because the Department number 4 does not exist in the D... View the full answer
Related Book For
Fundamentals Of Database Systems
ISBN: 9780133970777
7th Edition
Authors: Ramez Elmasri, Shamkant Navathe
Posted Date:
Students also viewed these programming questions
-
Kendra has been collecting empty bottles and cashing them in for money at regular intervals. She receives 15 cents for each bottle and collects an average of 500 bottles per week. The market rate of...
-
https://academic.oup.com/jcr/article/36/3/478/1847025 I need a summary of this article i put above.
-
Specify queries c, d, and f of Exercise 8.18 in both tuple and domain relational calculus. Exercise 8.18 Consider the LIBRARY relational database schema shown in Figure 8.14, which is used to keep...
-
Air pollution officials in Californias Central Valley have opened a new front in the war against urban sprawl, and regulators and environmental advocates throughout the state are watching closely....
-
A large flat horizontal sheet of charge has a charge per unit area of 9.00 %C/m2. Find the electric field just above the middle of the sheet.
-
When you invest your savings in a company, what is the difference between the return on your investment and the return of your investment?
-
With reference to Exercise 10.1, what can we say with \(95 \%\) confidence about the maximum error if we use the sample proportion as an estimate of the true proportion of complaints filed against...
-
iGAAP prohibits the use of the completed-contract method in accounting for long-term contracts. If revenues and costs are difficult to estimate, how must companies account for long-term contracts?
-
Fluid mechanics NUMERICAL PROBLEMS (4 X 3 = 12 Points) Q1. An oil flows through 50.0 m of cast iron pipe having a diameter of 0.25 m. If the volumetric flow is 0.40 m^3/s, determine the head loss in...
-
McGuire decides to start slow with a project testing the increased automation of their horse feed line. Below are the projected cost of the expansion in automation, given a 5 year useful life of the...
-
The point is to 1) create the form, 2) collect data from the form, 3) do some calculations with the data and 4) send output to the page that differs depending on what you filled in the form. You...
-
Simplify. Express answers with positive exponents. -1..3 a) (3xy)(2xy) c) (10x) 15xy-3 (3mn) 12m n6 b) (2) 4ab d) e) f) ps (1) (pr)(p-) (xy)(x ((x) (xy-3)-2 -1
-
calculate WACC for a Italian company operating in Healthcare Products sector assuming: a. application of H&BU concept and fair market value approach b. risk free rate on the level of return on 10...
-
Daniel Inc. expects to sell 5 , 0 0 0 ceramic vases for $ 3 0 each in 2 0 2 2 . Direct materials costs are $ 2 , direct manufacturing labour is $ 1 0 , and manufacturing overhead is $ 3 per vase....
-
The o matrix is defined by: (i) Prove the relation Ox with A2+ = 1. 01 = - (11) eiad = I cos a + io sin a where I is the 2 x 2 unit matrix. (ii) Find an analogous relation for the matrix oy defined...
-
a. Purchased $78,000 of raw materials on account. b. $76,000 in raw materials were used in production. Of this amount, $62,000 was direct materials and the remainder was indirect materials. c. Paid...
-
Blackstone Industries uses a combination of common stock, preferred stock, and debt financing. The company wants preferred stock to represent 10 percent of the total financing. They also want to...
-
Chao, Louis, and Mari, unrelated individuals, own all of the shares of Cerise Corporation. All three shareholders have been active in the management of Cerise since its inception. In the current...
-
When a failure occurs, the log is consulted and each operation is either undone or redone. This is a problem because a. Searching the entire log is time consuming b. Many redos are unnecessary c....
-
What is the difference between attributes and elements in XML? List some of the important attributes used to specify elements in XML schema.
-
Name some advantages of the MapReduce/Hadoop technology.
-
Each message in a digital communication system is classified as to whether it is received within the time specified by the system design. If three messages are classified, use a tree diagram to...
-
As in Example 2.1, camera recycle times might use the sample space \(S=R^{+}\), the set of positive real numbers. Let \[ E_{1}=\{x \mid 10 \leq x <12\} \quad \text { and } \quad E_{2}=\{x \mid 11 0\}...
-
A printed circuit board has eight different locations in which a component can be placed. If four different components are to be placed on the board, how many different designs are possible?
Study smarter with the SolutionInn App