How to make YTD queries

E

enders

Hi,

We have a database with sales in it. All items are kept like

(this should look okay if you use a fixed lettertype)

date product price number_of_items total
1-jan Prod A 10 5 50
1-feb Prod A 20 5 100
1-feb Prod B 5 15 75
1-mar Prod A 20 5 100

My manager wish to see the following report

Product Jan Feb Mar
Prod A 50 150 250
Prod B 75 75

Eventually if a new product is added is should come up.
I also have a product table.

Any suggestions ?

CE
 
A

Arvin Meyer

Have a look at Cross-tab queries. You'll first need to build a query as the
data source to ensure that you get the right data.

There is a query wizard which is helpful in creating the Cross-tab.

BTW, you do not need to store the total. the price * the number_of_items in
a query column will always compute the total for you.
--
Arvin Meyer, MCP, MVP
Microsoft Access
Free Access downloads:
http://www.datastrat.com
http://www.mvps.org/access
 

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

Top