Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

2(40 points : 25 for a, 5 for b, c, d) Physical database design: indexed cluster! Write SQL statements of the steps below in one

image text in transcribedimage text in transcribed

2(40 points : 25 for a, 5 for b, c, d) Physical database design: indexed cluster! Write SQL statements of the steps below in one script file and upload both the input script file and the runscript output to Blackboard. Add comments in your script for better readability; points will be deducted for a script with inadequate comment. a) Create an indexed cluster of the tables Department, Dept locations, and Project in the textbook Figure 5.7 (page 164). Specifically, cluster Dept locations and Project under Department using dnumber as the clustering key. Omit the foreign key constraint for mgrssn in the Department table, since the table Employee is omitted in this exercise. b) Insert the tuples shown in the textbook Figure 5.6 (page 162) into the clustered tables. Insert null for the column mgrssn of the Department table, since the table Employee is omitted in this exercise. c) Execute the following queries against the clustered tables: (1) retrieve tuples from each clustered table (i.e., Department, Dept locations, Project), (2) retrieve the location and the project (name) of a department named dministration. Note that, although the files of the three tables have been merged into one, we still see them as separate tables at the logical level d) Drop the index, clustered tables, and the cluster. 2(40 points : 25 for a, 5 for b, c, d) Physical database design: indexed cluster! Write SQL statements of the steps below in one script file and upload both the input script file and the runscript output to Blackboard. Add comments in your script for better readability; points will be deducted for a script with inadequate comment. a) Create an indexed cluster of the tables Department, Dept locations, and Project in the textbook Figure 5.7 (page 164). Specifically, cluster Dept locations and Project under Department using dnumber as the clustering key. Omit the foreign key constraint for mgrssn in the Department table, since the table Employee is omitted in this exercise. b) Insert the tuples shown in the textbook Figure 5.6 (page 162) into the clustered tables. Insert null for the column mgrssn of the Department table, since the table Employee is omitted in this exercise. c) Execute the following queries against the clustered tables: (1) retrieve tuples from each clustered table (i.e., Department, Dept locations, Project), (2) retrieve the location and the project (name) of a department named dministration. Note that, although the files of the three tables have been merged into one, we still see them as separate tables at the logical level d) Drop the index, clustered tables, and the cluster

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_2

Step: 3

blur-text-image_3

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

OpenStack Trove

Authors: Amrith Kumar, Douglas Shelley

1st Edition

1484212215, 9781484212219

More Books

Students also viewed these Databases questions

Question

What is the purpose of the Salary Structure Table?

Answered: 1 week ago

Question

What is the scope and use of a Job Family Table?

Answered: 1 week ago