Draw an er diagram to represent the database

Assignment Help Other Subject
Reference no: EM132195761

Objectives:

• Learn to implement advance SQL statements
• To practise joining tables for retrieving data
• To practise the use of relational set operators to merge data

Activities

Task

1) Create a new database called Food_Beverages and import the fileFood_Beverages.sql.

2) Draw an ER diagram to represent thedatabase.

3) Use this new database to implement the SQL statements to complete the following:

a) In a following SELECT statement, how many rows will there be in the output? Explain how you have derived at this number. Describe how you can confirm the number iscorrect.

SELECT P.ProductID, C.CategoryID FROM Product AS P, Category AS C;

b) Are all the rows in the output of (a) meaningful? How can you modify that SELECT statement so that the rows in the two tables are logically joined and every row in the output ismeaningful?

c) Display the ID and the shipped date of every order along with the ID and name of the company in charge of shippingit.

d) Show the name and the quantity of the product(s) being listed in eachorder.

e) List the full name and the title of the person which each employee reports to. The ID and last name of the employee should be included in theoutput.

f) Display the ID and contact person of the supplier of the discontinued products. The ID of the product and category ID it belongs to should be included in theoutput.

g) Show the average unit price of the products in each category. The name of each category should be included in theoutput.

h) List the name and title of every customer contact person from Berlin, followed by the full name and title of the employees based in London. The city should be included in the output. (hint: use a relational setoperator)

i) Show the orders which have more than 5 products listed in them? The Order ID and the number of products list in it should be in theoutput.

j) What is the largest discount given to a product beingordered?

Reference no: EM132195761

Questions Cloud

Strategy important to firm in twenty-first century landscape : What is the definition of competitive strategy, and why is this strategy important to firms in the twenty-first century landscape?
Create a memo using memo template : Revise the program to reflect the following changes: Use a for loop to prompt the student for the price of each book based upon the number of classes.
Describe the search processes you implemented : Describe the search processes you implemented (including search words, and databases you searched), for obtaining the papers for the SLP assignment.
What are the advantages of using narrative text : In an essay of 1,250-1,500 words, discuss and present the following: What are the advantages of using narrative text
Draw an er diagram to represent the database : Create a new database - Draw an ER diagram to represent the database - In a following SELECT statement, how many rows will there be in the output?
Interpretation of the coefficient of x 1be : Suppose a multiple regression model is given by y =1.61x 1+5.58 x2 +30.48 What would an interpretation of the coefficient of x 1be?
What is the purpose of the sopa and pipa : CPSC 311 As an industry insider, look at both acts and think about the benefits and the drawbacks. In a research paper, cover the following questions.
Adults rated the effectiveness of advertisements : In a? study, a random sample of 20 adults rated the effectiveness of advertisements. Each adult rated an advertisement that lasted 30 or 60 seconds.
How would you respond to this observation : The problem with risk analysis is that it is possible to imagine virtually anything going wrong on a project.

Reviews

Write a Review

Other Subject Questions & Answers

  Concept of speed treatment to treat your patients

You've just been promoted to the manager of your medical office. One responsibility you now have is to research and determine if you want to use the concept of speed treatment to treat your patients.

  Research inpatient and ambulatory or ancillary health care

Research inpatient and ambulatory or ancillary health care organizations.Explain transformational improvement in relation to organizational performance.

  How are conference presentations professionally relevant

Effective clinical innovations and the dissemination of research findings are key elements in the growth and development of the psychology profession.

  Define substance use in your own words

Consider the problem of substance use in America. In 1,250-1,500 words, do the following: Define substance use in your own words. Discuss why Americans seemingly have such a desire for illegal narcotics

  What is political rule in augustine

What is political rule in Augustine? How does he use the distinction between the civitas Dei and the civitas terrena in constructing his notion of the state?

  Different spiritual assessment tools

Analyze the ease of use and comprehensiveness of the data collected. Report on the validity and reliability of the tool

  Describe way in which you would evaluate success of program

Describe the way in which you would evaluate the success of your program. Discuss the wisdom behind the strategy you would use to test the hypothesis.

  Discuss where and when surveillance cameras

Discuss where and when surveillance cameras are acceptable and if it should matter if they are hidden or openly displayed.

  Proactive crisis management and media

Is the best way to ensure a positive experience with the media and to be proactive in crisis management is to develop relationships with the media before a crisis.

  Future use of our depleting natural resources

Could someone please explain to me the predictions on the future use of our depleting natural resources. What actions do you personally take to conserve the Earth's natural resources? If you do not currently take action, explain what you could do ..

  Explain police deviance and corruption

There are many theories attempting to explain police deviance and corruption. Identify one of them and explain it from the organizational

  Differentiate between action-orientated and people-oriented

Differentiate between action-orientated, people-oriented and cerebraloriented roles in a team as described by Belbin Explain the nine team roles as explained by Belbin

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd