Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Section A: Rewrite the following queries:Section B: Answer the following questions based on the query given SELECT EMP _ LNAME, EMP _ FNAME, EMP _

Section A: Rewrite the following queries:Section B: Answer the following questions based on the query given
SELECT EMP_LNAME, EMP_FNAME, EMP_AREACODE, EMP_GENDER
FROM EMPLOYEE
WHERE , EMP_GENDER AND EMP_AREACODE =?'615'
ORDER BY EMP_LNAME, EMP_FNAME;
What is the likely data sparsity of the EMP_GENDER column?
What index would you recommend?
SELECT EMP_LNAME, EMP_FNAME, EMP_DOB, YEAR (EMP_DOB) AS YEAR
FROM EMPLOYEE
WHERE YEAR (EMP_DOB)=1966;
What is the likely data sparsity of the EMP_DOB column?
What index would you recommend?
SELECT * FROM emp WHERE lname = 'FULLER' AND empid ='439394';
SELECT * FROM Employee WHERE salary/12=4000
SELECT P_NAME FROM PRODUCTS WHERE P_PRICE -10=7
SELECT P_NAME FROM PRODUCTS WHERE
P-MIN=P-REORDERP-QOH=10FLP-QOH AND P-MIN=P-REORDER AND P-QOH=10
SELECT PNAME FROM PRODUCTS WHERE PPRICE >10 AND VSTATE =
'FL'
(You know that only a few vendors are located in Florida)
SELECT PNAME FROM PRODUCTS WHERE NOT (PPRICE >10.00)
SELECT * FROM Employee WHERE NOT (EMPSEX='M')Assume that 10,000 vendors are distributed as shown in Table 1.
Table 1 Distribution of Vendors by State
Using Table 1 as an example, create two alternative access plans.
Table 2 Comparing Access Plans and I/O Costs
image text in transcribed

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

Students also viewed these Databases questions