Based on the tables below,which of the following ANSI SQL commands would return the average customer balance grouped by SalesRepNo? GENERAL SALES DATABASE:
SALESREP
CUSTOMER
A) SELECT AVG (Balance)
FROM CUSTOMER
WHERE SalesRepNo;
B) SELECT AVG (Balance)
FROM CUSTOMER
GROUP BY SalesRepNo;
C) SELECT AVG (Balance)
FROM CUSTOMER,SALESREP
WHERE SALESREP.SalesRepNo = CUSTOMER.SalesRepNo;
D) SELECT AVG (Balance)
FROM CUSTOMER
ORDER BY SalesRepNo;
E) SELECT AVG (BalancE)
FROM CUSTOMER,SALESREP
WHERE CUSTOMER.SalesRepNo = CUSTOMER.SalesRepNo
HAVING SalesRepNo;
Correct Answer:
Verified
Q85: When one SQL query is embedded in
Q90: The following database will be used in
Q90: Given a table with the structure: EMPLOYEE
Q95: The following database will be used in
Q95: In an SQL query,which SQL keyword is
Q107: What is SQL?
Q108: Given the table CUSTOMER(CustID,Name,PhoneNumber,AccountBalance),write the standard SQL
Q111: Briefly describe subqueries and joins.Explain when each
Q112: What are SQL Built-in Functions?
Q113: Distinguish between the HAVING clause and the
Unlock this Answer For Free Now!
View this answer and more for free by performing one of the following actions
Scan the QR code to install the App and get 2 free unlocks
Unlock quizzes for free by uploading documents