09. Hey, what states are our publishers in and how many publishers are in each state? I don't need the names of the publishers; I just need the number in each state. But I do need to see them sorted by the number in each state with the largest number first.
Now you start to add the use of functions to manipulate the results
Sort by number and then by state, in that order
[top]
10. The fire insurance people need to know how much our book stocks are worth. We need a list of the replacement costs for each our books. They don't need to know the individual cost or the number of copies we have, but they do want to see the replacement costs from largest to smallest, to include the titles of the books that will need replacing.
For each book, show:
More functions, but instead of using a function on the results of a select query, you now you have to use the Build tool to create a new value that doesn't exist in the table as it stands
Sort by Total Value, then by book title, in that order
[top]
11. What and how many books do we have on order and how much of a break are we getting on the price? I need to know how much of a price break we get on each book and total savings we are getting on each order.
Show:
This will require
Sort by Total Savings, then by book title, in that order
[top]
12. I need to rattle some publisher cages about slow deliveries. Get me a list of the publishers as well as their cities and states (or countries). Sort it by publishers because I also want to see how many of each title we have ordered from each one and how much each order will cost if we have to buy it locally at full retail price.
This calls for values from all orders, whether already delivered or not. Show:
You will need the number of books ordered, but not in the results of the query
Sort by the total cost of the order, then by the publisher name, in that order
[top]
13. For no particular reason, of the books in our collection, I would like to know what authors are published by what publishers and how many titles each author has by that publisher. Make it so I can do it by individual publisher.
Include in the query design:
Sort so that the number of titles shows the largest number of titles per author to the smallest number of titles per author, and the associated authors are sorted alphabetically. Arrange the resultant datasets first by titles per author, then by associated authors.
[top]
14. OK, this is the last request. Our investments have lost value and this has cut into our budget. We need to know where we can save some money fast. Get a list of all our outstanding orders, ones that we have sent to the publishers, but that the publishers have not yet filled. We need to see how much money we have allocated for these orders so we can cancel them if we have to. I promise, this is the last one.
This query could be the source of a report, which would present a formatted paper copy of the result of this query.
For each distinct order that has not been received yet, show only the following fields:
This calls for a select across multiple tables, newly built fields of new data, application of functions, and use of the NULL criteria. This is a request for a list of things that have not yet happened, not a list of things that have happened already.
Sort by the publisher name, then by the book title, and then by the date of the order.
[top]