Subtotal query

M

Malcolm Miles

This would appear to be simple but as a novice Access user I would like
help generating a subtotal query.

I have a table of customers, products purchased and cost:

customer1 product1 price
customer1 product2 price
customer1 product2 price
customer2 product1 price
customer2 product3 price

I would like to generate a query that produces a total cost per customer
for all products purchased:

customer1 totalprice
customer2 totalprice

I would greatly appreciate it if someone could help with constructing such
a query.
 
A

ashg657

Create a new select query containing your 2 relevant fields (customerno &
price), and simply "Group By" on CustomerNo by clicking on the "Totals"
button in query design view, and select Group By in the Totals row under your
customerno field.
You can then use "TotalPrice:price" to change the column heading in your
generated total price column.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

update query with summary 2
Database summary 4
Multiple values to link to other tables 2
update subquery 2
Max date 3
matching a customer with a twist.. 1
Query - Crosstab ? 2
Variable number of columns in query 0

Top