Question

Seeking help/ explanation for a SQL question.

1.) How many different customers have made orders?

Tables: CLOTHES ClOID, Type, Brand, Descript, Matrial, MadeInCountry, Size, Price, SID, POID) CUSTOMER (CustID, Cname, CbirthE-R Diagram: Implementation Model Quantity CLOTHES H SUPPLIER CUSTOMER Places 여 PURORDER Contains POID ORDER ShiplD SentTo SHDatabase Schema (The records in the tables represent only a sample of the data contained in the real database CLOTHES Brand MORDER SHIPMENT OrderShipID ShipID POID Varchar(10) Varchar (10) Varchar (10) SH0001 SH0001 SH0001 SH0001 SH0002 SH0002 SH0002SHIPMENT Trackingkun Varchar (25 Shipstreet Varchar (100 Shipcity Varchar (25 Shipstate Shipzip EstimateDeliveryDate CustID D

Tables: CLOTHES ClOID, Type, Brand, Descript, Matrial, MadeInCountry, Size, Price, SID, POID) CUSTOMER (CustID, Cname, Cbirthdate, Cemail, Cstreet, Ccity, Cstate, Czip, CreditCard, CsignupDate) ORDER SHIPMENT (OrderShipiD, Ship:D, Po:D) PURORDER (POID, PurchaseDate, Shipoption, Quantity, CustID) SHIPMENT (ShipID, TrackingNum, Shipstreet, Shipcity, Shipstate, Shipzip, EstimateDeliveryDate, CustID) SUPPLIER (SID, Sname, Sstreet, scity, Sstate, Szip, Slicense)
E-R Diagram: Implementation Model Quantity CLOTHES H SUPPLIER CUSTOMER Places 여 PURORDER Contains POID ORDER ShiplD SentTo SHIPMENT
Database Schema (The records in the tables represent only a sample of the data contained in the real database CLOTHES Brand Material varcharく Wool MadeIncountrysize Varchar(25 Mongolia ype Varchar (200 Trench coat with lapel collar and turned-u FlovyV-neck dress with full cut long aleeven Leather Oxford ghoes Numeric(5,2 char ( 5 Varchar (10 00001 CL0001 CL0002 CL0003 CL0004 CL0005 CL0006 S0001 s0011 S0006 S0004 S0003 S0002 Coats Esprit Polyester Indonesia china China Indonesia 00051 ion Leather Intelerce Absorbine Jr Solstice V-neck sveater with long XI 130.46 00019 00026 00039 Jackets High-waisted pants. FrontNylon Shirt with round neck and Cotton Tops short sleeves CUSTOMER Cbirthdate Date 2003-11-06 1995-06-0 1985-09-08 Cemail Varchar(50) ccity varchar (25) Tallahassee CreditCard varchar (25) 4357285859108340 6450936919494070 4520439540339660 VarcharVarchar (25) C0001 C0002 C0003 Varchar(100) 4939 Lsd 18th Dr 1611 62nd Street 9712 Olmsted Road 6597 Holbrook Road 1843 B7th Street char/2) varchar(5} 32391 66048 Date 2010-09-03 2009-12-14 1999-10-18 FL Bren.WA1998 Ada.NOEL5831 Sar.NO3202ronumentmai1.com Sariah Noble har CR1983 real c0005 C0006 1994-12-21 Be. KE5542 monumentmail.com Domi.cCOOK6B57 Pmailinator.com 2229 Broad Street 4978039467855790 6443996255978930 1993-12-21 Doninick Cook 983-10-19 994-04-10
ORDER SHIPMENT OrderShipID ShipID POID Varchar(10) Varchar (10) Varchar (10) SH0001 SH0001 SH0001 SH0001 SH0002 SH0002 SH0002 SH0003 SH0003 os0001 oS0002 OS0003 OS0004 oS0005 oS0006 OS0007 OS0008 os0009 00001 00002 00003 00004 00005 00006 00007 00008 00009 PURORDER PurchaseDate Shipoption Quantity stID POİD Varchar(10)Date 00001 00002 00003 00004 00005 00006 00007 00008 Varchar (25) Integer Standard Standard Same Day Express Express Standard Standard Express Varchar(5) C0001 C0001 C0001 C0001 C0001 C0002 C0002 C0003 2004-07-06 2018-03-14 2006-11-15 2015-03-18 2016-12-21 2002-12-30 2002-06-13 2014-07-20
SHIPMENT Trackingkun Varchar (25 Shipstreet Varchar (100 Shipcity Varchar (25 Shipstate Shipzip EstimateDeliveryDate CustID Date ShipID archar (10 Char (2 archar(5 Varchar(5 SH0002 SH0003 SHO004 Washinton DC Canton Warren San Antonio TX 20530 44720 4485 9008032372 685975590 6425 02489 2016 Jenna Pass 1457 Gulseth Terrace 22 Kingsford Alle 4022 Tennessee Road 2016-06-10 2017-12-20 2018-09-02 C0011 C0020 CO003 Co004 OH OH 2443813388 78260 SUPPLIER Scity Varchar(25) Char (2) Varchar (5 Varchar (10) Szip Slicense SID Sname Sstreet Sstate Varchar (100) Varchar(5) Varchar (25) dr 885 419 Cİtyfront Plaza 881 75012 30906 27744 01160 95468 S0002 S0003 S0004 S0005 S0006 Serenity Wilder Christopher Sims 3940 St Johns Street Auqusta Bree Salinas Leonardo Gilbert 1666 Kreiter Ave 2aria Cross Irvin TX GA NC MA. CA 224290A R289700 JO6847E RW5066K ST6201K 9105 130th Street Durham 3665 Houston Road San Jose
1 0
Add a comment Improve this question Transcribed image text
Answer #1

Select count(c.custid) from customer c inner join purorder p on c.custid=p.custid

In above query we joined 2 tables to get customers who have purchased an order. And we are count to count number of customers purchased order.

Please comment if anything required

Add a comment
Know the answer?
Add Answer to:
Seeking help/ explanation for a SQL question. 1.) How many different customers have made orders? Tables: CLOTHES ClOID, Type, Brand, Descript, Matrial, MadeInCountry, Size, Price, SID, POID) CUSTOMER...
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
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