Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Compare the cost of two different query plans for the following query: salary > 40000 select (EMPLOYEE DNO=DNUMBER DEPARTMENT) Use the database statistics in Figure

Compare the cost of two different query plans for the following query:

image text in transcribed

salary > 40000 select (EMPLOYEE DNO=DNUMBER DEPARTMENT) Use the database statistics in Figure 19.8. You don't have to give the exact number, an approximation is good enough.

Figure 19.8 Sample statistical information for relations in Q2. (a) Column information. (b) Table information. (c) Index information. (a) Table_name Low_value Column_name Plocation Pnumber Num_distinct 200 1 High_value 200 2000 2000 1 50 1 50 Dnum Dnumber 50 1 50 PROJECT PROJECT PROJECT DEPARTMENT DEPARTMENT EMPLOYEE EMPLOYEE EMPLOYEE Mgr_ssn 1 50 10000 Ssn 1 50 10000 50 1 Dno Salary 50 500 1 500 (b) Blocks Num_rows 2000 100 Table_name PROJECT DEPARTMENT EMPLOYEE 50 5 10000 2000 (c) Blevel" Leaf_blocks Distinct_keys 200 1 4 Index_name PROJ_PLOC EMP SSN EMP_SAL Uniqueness NONUNIQUE UNIQUE NONUNIQUE 1 50 10000 1 50 500 *Blevel is the number of levels without the leaf level. Figure 19.8 Sample statistical information for relations in Q2. (a) Column information. (b) Table information. (c) Index information. (a) Table_name Low_value Column_name Plocation Pnumber Num_distinct 200 1 High_value 200 2000 2000 1 50 1 50 Dnum Dnumber 50 1 50 PROJECT PROJECT PROJECT DEPARTMENT DEPARTMENT EMPLOYEE EMPLOYEE EMPLOYEE Mgr_ssn 1 50 10000 Ssn 1 50 10000 50 1 Dno Salary 50 500 1 500 (b) Blocks Num_rows 2000 100 Table_name PROJECT DEPARTMENT EMPLOYEE 50 5 10000 2000 (c) Blevel" Leaf_blocks Distinct_keys 200 1 4 Index_name PROJ_PLOC EMP SSN EMP_SAL Uniqueness NONUNIQUE UNIQUE NONUNIQUE 1 50 10000 1 50 500 *Blevel is the number of levels without the leaf level

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

Budgets And Financial Management In Higher Education

Authors: Margaret J. Barr, George S. McClellan

3rd Edition

1119287731, 9781119287735

More Books

Students also viewed these Finance questions

Question

What has been the evolution of HRM?

Answered: 1 week ago

Question

What would you do?

Answered: 1 week ago