Prev | Current Page 444 | Next

Carl Reynolds and Paul Tymann

"Schaum's Outline of Principles of Computer Science"

8
Line Item
Consignment_Seller
Write SQL queries to report the following information:
a Report all of the consignment sellers located in NY, and list them in order by their consignment fee
percentages.
b Find all of the items in the store that are on consignment from ???Parker Smith???. Report only the
items for sale (Price_Sold is NULL).
c Report the total of all sales during last March.
d Find all the items on consignment from ???Parker Smith??? that sold this month.
e Report the amount due to ???Parker Smith??? for all sales of his items this month.
f Report all sales of items not on consignment (Consignment_Seller_ID is NULL) this month.
g Report the profit on all non-consignment items this month.
8.6 When a customer buys an item (or several) from the store, several changes to database tables will occur.
Explain what those might be.
8.7 The owner of the antique store doesn??™t want to train his people in SQL, or to teach them about all the
tables in the database. He asks you to write a program that will take sales information, and then make all
the changes automatically, including whatever error checking may be necessary. The clerk will enter
a customer phone number (assume this is used as the Customer_ID primary key in the Customer
table), an item ID (from a tag on the item), and the sale price.


Pages:
432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456
sufit podwieszany praca w holandii Okulary mieszkania dieta light