Answered step by step
Verified Expert Solution
Question
1 Approved Answer
SQL: pls treat each line as independent: department table - Primary key: dnumber attribute dept_location table - Primary key: combination of (dnumber, dlocation) attribute Foreign
SQL: pls treat each line as independent:
department table - Primary key: dnumber attribute dept_location table - Primary key: combination of (dnumber, dlocation) attribute Foreign keys: dnumber references department (dnumber) with on update cascade and on delete cascade project table - Primary key: pnumber attribute Foreign keys: dnum references department (dnumber) with on delete cascade fund source table - Primary key: fsid attribute Foreign key: pnumber references project (pnumber) with on update cascade and on delete cascade budget table - Primary key: combination of (dnumber, bcode) attributes Foreign keys: [1] dnumber references department (dnumber) with on update cascade and on delete cascade [2] fsid references fund_source (fsid) with on delete set null customer table - Primary key: cid attribute Foreign key: fsid references fund_source (fsid) with on update cascade Determine what will happen if the following SQL transaction (i.e., insert, update, delete or similar command) is executed based on the given database schema and state descriptions. Select the most appropriate response(s) below based on the fact that multiple errors could be generated by the transaction. insert into department values ('Innovation', 2, 333445555, '19800704) The transaction will generate one or more key integrity errors. The transaction will generate one or more entity integrity errors. The transaction will generate one or more referential integrity errors. The transaction will execute successfully (i.e., no errors will be generated). insert into dept_locations values (null, 'Stafford'); The transaction will generate one or more key integrity errors. The transaction will generate one or more entity integrity errors. The transaction will generate one or more referential integrity errors. The transaction will execute successfully (i.e., no errors will be generated). insert into budget values (5, null, 516000,17); The transaction will generate one or more key integrity errors. The transaction will generate one or more entity integrity errors. The transaction will generate one or more referential integrity errors. The transaction will execute successfully (i.e.. no errors will be generated). insert into customer values ('bank0', null, 'Dallas', 350000,2 ); The transaction will generate one or more key integrity errors. The transaction will generate one or more entity integrity errors. The transaction will generate one or more referential integrity errors. The transaction will execute successfully (i.e.. no errors will be generated). insert into project values ('ProductQ', 10, 'Sugarland', 4); The transaction will generate one or more key integrity errors. The transaction will generate one or more entity integrity errors. The transaction will generate one or more referential integrity errors. The transaction will execute successfully (i.e., no errors will be generated). insert into fund_source values (7,11000,10000,10); The transaction will generate one or more key integrity errors. The transaction will generate one or more entity integrity errors, The transaction will generate one or more referential integrity errors. The transaction will execute successfully (i.e., no errors will be generated). delete from fund_source where remaining
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started