I have a database that contains production and status tables. The production table has part number, status_date and status_ID. The status table contains an entry for each status Id along with the quantity. Every day entries are made in it by part number showing the quantity of each part in each status. I can pull a query that shows all the entries for a given period of time, but I want to count them up and only show total numbers. So for example, rather than show each value entered for WidgetA for the past month, I was to show the total number of WidgetA's worked on as well as the subtotal of each status type. I'm thinking an array would be the way to go, but I'm not sure how to get started.