Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Write a query to display each state, and the total number of customers in that s

ID: 3596404 • Letter: W

Question

Write a query to display each state, and the total number of customers in that state. Only include those states that have less than 100 customers.

(TCO 7) Write a query to display each state, and the total number of customers in that state. Only include those states that have less than 100 customers SalesRep PK RepID int Customer varchar(20) varchar(20) PK CustomerlD int LastName FirstName CommissionRatedecimal(10,2) LastName varchar(20) FirstName varchar(20) Street City State Zipcode Balance varchar(20) varchar(20) char(2) char(5) decimal(10,2) int Order PK OrderlD int FK1 ReplD FK1 CustomerlD int OrderDate date ShipDate date Part PK PartID int OrderLine Description varchar(20) UnitsOnHand int ItemClass Retail Cost PK,FK1 OrderlDint PK,FK2 PartID int char(4) decimal(10,2) decimal(10,2) Quantity int

Explanation / Answer

SELECT C.STATE,count(C.CUSTOMERID) FROM CUSTOMER C

GROUP BY C.STATE,C.CUSTOMERID

HAVING COUNT(C.CUSTOMERID)<100

Please excute the above query you will get the out put

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote