
PUZZLE 45 PEPPERONI PIZZA 183
PUZZLE
45 PEPPERONI PIZZA
A good classic accounting problem is to print an aging report of old
billings. Let’s use the Friends of Pepperoni, who have a charge card at
our pizza joint. It would be nice to find out if you should have let club
members charge pizza on their cards.
You have a table of charges that contains a member identification
number (
cust_id), a date (bill_date), and an amount (pizza_amt).
None of these is a key, so there can be multiple entries for a customer,
with various dates and amounts. This is an old-fashioned journal file,
done as an SQL table.
What you are trying to do is get a sum of amounts ...