subject
Engineering, 16.05.2020 13:57 dpazmembreno

Consider the following relations:
Emp(eid: integer, ename: varchar, sal: integer, age: integer, did: integer)
Dept(did: integer, budget: integer, floor: integer, mgr_eid: integer)
Salaries range from $10,000 to $100,000, ages vary from 20 to 80, each department has about 5 employees on average, there are 10 floors, and budgets vary from $10,000 to $1M. You can assume uniform distribution. For each of the following queries, which of the listed index choices would you choose to speed up the query? Explain briefly (no more than 3 lines).
Query 1: Print ename, age, and sal for all employees.
Primary (clustered) hash index on (ename, age, sal) fields of Emp.
Secondary (unclustered) hash index on (ename, age, sal) fields of Emp.
Primary B+ tree index on (ename, age, sal) fields of Emp
Secondary hash index on (eid, did) fields of Emp.
No index.
Query 2: Find the dids of departments that are on the 10th floor and have a budget of less than $15,000.
Primary index on the floor field of Dept.
Secondary index on the floor field of Dept.
Primary B+ tree index on (floor, budget) fields of Dept.
Secondary B+ tree index on (floor, budget) fields of Dept.
No index.

ansver
Answers: 2

Another question on Engineering

question
Engineering, 04.07.2019 18:10
Apipe with an outside diameter of 15 cm is exposed to an ambient air and surrounding temperature of -20°c. the pipe has an outer surface temperature of 65°c and an emissivity of 0.85. if the rate of heat loss from the pipe surface is 0.95 kw per meter of length, the external convective heat transfer coefficient (h) is: (a) 12.5 w/m"k (b) 18.6 w/mk (c) 23.7 w/mk (d) 27.9 w/mk (e) 33.5 w/mk
Answers: 1
question
Engineering, 04.07.2019 18:10
Water at 55c flows across a flat plate whose surface temperature is held constant at 95c. if the temperature gradient at the plate's surface for a given value of x is 18 c/mm, find a) local heat transfer coefficient. b) heat flux
Answers: 3
question
Engineering, 04.07.2019 18:10
Journeyman training is usually related (clo2) a)-to specific tasks b)-to cost analysis of maintenance task c)-to control process to ensure quality d)-to installation of machinery
Answers: 2
question
Engineering, 04.07.2019 18:20
Select any two (2) areas of applications of chain-drive. (clo4) a)-permanent lubrication necessary b)-hydraulic forklift truck operation c)-rigging and heavy moving materials d)-relatively high maintenance costs e)-costlier than belt drives
Answers: 2
You know the right answer?
Consider the following relations:
Emp(eid: integer, ename: varchar, sal: integer, age: integer...
Questions
question
Biology, 24.02.2021 18:40
question
Social Studies, 24.02.2021 18:40