The average amount of their orders , Database Management System

Make SQL statements for the following scenarios. Your response should contain SQL statement, output and any other assumptions you have made to arrive at the answer.
For Colorado customers compute the average amount of their orders and the number of orders placed. The result should contain the customer number, customer last name, average order amount and the number of orders placed.

Query:

selectc.CUSTFIRSTNAME, c.CUSTLASTNAME, avg(p.PRODPRICE), count(ol.ORDNO) from customer c,ordertblot,ordlineol,product p where c.custno=ot.custno and ot.ordno=ol.ordno and p.PRODNO=ol.PRODNO group by c.CUSTFIRSTNAME,c.CUSTLASTNAME;

440_00.png

Posted Date: 3/20/2013 7:49:15 AM | Location : United States







Related Discussions:- The average amount of their orders , Assignment Help, Ask Question on The average amount of their orders , Get Answer, Expert's Help, The average amount of their orders Discussions

Write discussion on The average amount of their orders
Your posts are moderated
Related Questions
What is known as fudge factor? The number of partitions is enhanced by a small value called the fudge factor, which is usually 20 percent of the number of hash partitions compu

Give the Introduction of OBJECT DESIGN Strategies which are selected during system design are carried out in object-oriented design. In this procedure, objects which are identi

Explain the two types of participation constraint.  Total: The participation of an entity set E in a relationship set R is said to be total if each entity in E participates i

What are the different approaches for database design? There are two basic approaches for database design which are as follows: Attribute driven: It compiles a list of att

Illustrate the view of software architecture A model is a semantically closed abstraction of system composes of elements. It can be visualized using any of the following five v

How the time stamps are implemented Use the value of the system clock as the time stamp. That is a transaction's time stamp is equivalent to the value of the clock when the tra

The Transactions- A transaction is definite as the unit of work in a database system. Database systems that deal with a huge number of transactions are also termed as transaction p

Find out the names of all employees who work for first Bank Corporation from database. SELECT EMPLOYEE_NAME FROM WORKS WHERE COMPANYNAME = ‘First Bank Corporation';

What is relational model feature? A relational model feature is much more data independence than some other database models.

This project requires you to create a database design.  Your design will be documented in a set of Entity-Relationship diagrams.  Draw a set of Entity-Relationship diagrams to mode