Question

Suppose we have the following two tables (pk is in bold):        EMP (E#, Ename, Address, D#)...

Suppose we have the following two tables (pk is in bold):

       EMP (E#, Ename, Address, D#)

       SAL_HISTORY (E#, Raise#, Salary, Raise_Date, Reason)

Assume that 90% of queries involving salary is based on the most recent salary. How could you denormalize the above tables to improve the performance.

0 0
Add a comment Improve this question Transcribed image text
Answer #1

Answer)
Tables are:

EMP (E#, Ename, Address, D#)

SAL_HISTORY (E#, Raise#, Salary, Raise_Date, Reason)

Based on the above table structures, we have the information that 90% of queries involving salary are based on the most recent salary which is depicted by the column Salary as the most recent Salary.

Thus for de-normalizing the above tables for improving performance, we can have the tables as:

EMP (E#, Ename, Address, D#, CurrentSalary)

SAL_HISTORY (E#, Raise#, Salary, Raise_Date, Reason)

We can add the column CurrentSalary to the table EMP, which would mean that we can access the CurrentSalary form the EMP table only and do not have to perform joins with SAL_HISTORY table for the current salary. As 90% of the queries involving salary is based on the most recent salary thus this would be the correct solution.

**Please Hit Like if you appreciate my answer. For further doubts on the question or answer please drop a comment, I'll be happy to help. Thanks for posting.**

Add a comment
Know the answer?
Add Answer to:
Suppose we have the following two tables (pk is in bold):        EMP (E#, Ename, Address, D#)...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • The following ERD and two tables represent a partial model similar to what we used in...

    The following ERD and two tables represent a partial model similar to what we used in class. Answer all questions by writing SQL syntax to solve each. If a question requires more time, please move on to the next. Employee EmpNo (PK) Ename Job ManagerID HireDate Salary Commission DeptNo (FK) Department DeptNo Dname Location 10 ACCOUNTING NEW YORK 20 RESEARCH DALLAS 30 SALES CHICAGO 40 OPERATIONS BOSTON Department DeptNo (PK) Dname Location 1400 Employee Monthly EmpNo Ename Job ManagerID HireDate...

  • PROBLEM STATEMENT: Suppose you have a client that has given you the following business rules to...

    PROBLEM STATEMENT: Suppose you have a client that has given you the following business rules to form the basis for a database design. The database must enable the manager of a company dinner club to mail invitations to the club’s members, to plan the meals, to keep track of who attends the dinners, and so on. Each dinner serves many members, and each member may attend many dinners. A member receives many invitations, and each invitation is mailed to many...

  • 4. Matlab Solvers: A Case Study in Mechanics Suppose we have two objects orbiting in space,...

    4. Matlab Solvers: A Case Study in Mechanics Suppose we have two objects orbiting in space, with masses 1 - and , rotating around each other. For example, think of the earth and the moon, where the moon moves around the earth at distance 1. (Of course, here both the masses and the distance are normalized.) A third object, which is relatively much smaller and does not affect the motion of the first two, is also orbiting in space. Think...

  • C++. Need some help getting started. We will also have the following two functions: 1. A...

    C++. Need some help getting started. We will also have the following two functions: 1. A mutate function that randomly modifies a chromosome. 2. A crossover function that takes two chromosomes and splits each one at the same spot, then combines them together. Our genetic algorithm works by iterating over generations of chromosomes via the following process: 1. Generate random population. 2. Until we get an answer that is good enough, do the next steps in a loop: (a) Do...

  • QUESTION 9. In recent years, it has been suggested that both China and the US have...

    QUESTION 9. In recent years, it has been suggested that both China and the US have engaged in currency manipulation or ‘competitive devaluations’. All else the same, from this we can conclude: A.  Chinese goods will be less expensive in US markets in the short-run, but US goods will be more expensive in China. B.  US goods will be less expensive in China in the short-run, but Chinese goods will be more expensive in the US. C. Chinese and US made goods...

  • Barnes Boards produces skateboard parts for six different major US skateboard manufacturers. Barnes specializes in the...

    Barnes Boards produces skateboard parts for six different major US skateboard manufacturers. Barnes specializes in the production of trucks, which attach the skateboard wheels to the skateboard deck and allow the rider to turn the skateboard.  Barnes Boards' trucks are made primarily of molded aluminum.  Currently, Barnes Boards produces two different types of trucks: The 700 and the 775. The 700 has the highest sales and for many years was the only truck produced by Barnes Boards. As a result of the...

  • A: China's makhle owe the country as we environmental problems. One of the trip is the...

    A: China's makhle owe the country as we environmental problems. One of the trip is the yearly due ons which beroes the country. They po niskot business hills of dollar and leave parts of the typened in yellow dist. The problem severe's even affecting China's bors as well as t housalds of kill s The duoen om Marin May. Stwins pick up dins from the vast desert and plains of the newestem China and Moegli. The dirt is the carried...

  • We conducted a comprehensive literature search on drones in conservation up to October 2nd 2018, in...

    We conducted a comprehensive literature search on drones in conservation up to October 2nd 2018, in line with related studies [10,11,35]. All searches were done by the same person in English, mainly using Google Scholar. This was further complemented through reference harvesting, citation tracking, abstracts in conference programs, and author search, using Research Gate and Mendeley (see PRISMA Flowchart in Supplementary Figure S1 Checklist and list of studies reviewed in Table S1). We then removed duplicate and unrelated results. Finally,...

  • What was Novartis ́ main challenge in managing talent in China? Novartis case . Global Talent...

    What was Novartis ́ main challenge in managing talent in China? Novartis case . Global Talent Management at Novartis I do not know how to post the PDF case? cloud you tell me how to give the case Sourcing Talent Globally The company was actively involved in sourcing talent from increasingly dispersed locations. Managers were encouraged to keep an updated list of leadership talent. In addition, the company 7 708-486 Global Talent Management at Novartis had recently expanded its hiring...

  • Is there one universal way for a MNC to motivate its employees around the world to...

    Is there one universal way for a MNC to motivate its employees around the world to exert maximum effort and be accountable for their results? case: Global Talent Management at Novartis I do not know how to give you the whole case Sourcing Talent Globally The company was actively involved in sourcing talent from increasingly dispersed locations. Managers were encouraged to keep an updated list of leadership talent. In addition, the company 7 708-486 Global Talent Management at Novartis had...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT