BUYER TABLE
Inserting Values
INSERT INTO `buyer` (`Buyer_ID`, `BuyerName`, `ContactNo`, `Address`) VALUES ('100', 'Janeth Antoque', '09367844','Talisay City, Cebu'), ('101', 'Lerma Bastasa', '09224968', 'Carcar, Cebu'), ('102', 'Cristill Sigue', '09234567','Cebu City'), ('103', 'Keren Villaser', '09167890', 'Lapu Lapu City'), ('104', 'Glydel Bastatas', '09267899', 'Naga City');
SELLER TABLE
Inserting Values
INSERT INTO `seller` (`Seller_ID`, `SellerName`, `ContactNo`, `Address`) VALUES ('201', 'John Michael Fajardo','09334567', 'Talisay, Cebu'), ('202', 'John Mark Arejola', '09435668', 'Guba, Cebu City'), ('203', 'Shirwen Englaterra', '09234512', 'Budlaan, Cebu City'), ('204', 'Jade Ramas', '09167897', 'Basak Pardo, Cebu City'), ('205','Kit Ian Chiong', '09224321', 'Linao, Minglanilla Cebu');
PRODUCTS TABLE
PROBLEMS :
- For Simple Query
The number of sold products is increasing and the manager wants to know ,
who are the buyers of the products and their information , so that they`ll improve the quality of the product and will give discounts .
- For Filter Query
The Buyer wants to buy the product which is only worth of one peso each and
Also what to know what are those products.
. 
- For Ordered by
The Manager wants to know who are the sellers of their products and she/he requests to have the list of the Sellers with their names in Ascending Order and their address .
- For Union
The manager wants to have the list of sellers and buyers to give them some rewards.
He/She just need their complete name and address.
- For Join
The manager told the sellers to list down the name of buyers with the products that they purchased . Because the manager wants to give discount to the buyers.
No comments:
Post a Comment