Query layout

M

Mark

I have a query (qry1) which lists 3 different fields:

Date Par1 Par2 Par3
.... $10 $20 $30
.... .... .... ....

How can I create a query layout to calculate some basic statistics
(Avg, Var, Stdev, ..) and have the results displayed in the following
way:

Var Avg Var StDev
Par1 ... ... ....
Par2 ... ... ....
Par3 ... ... ....

Currently, I created a query (qry2) based on qry1 to compute these
statistics, but all results are lined up in one single row. How can I
force qry2 to be split in multiple columns?

Thanks for your help.
 
E

Ed Robichaud

One solution would be to create a report. This would allow you to format
the layout as you wish. You could use the same query as the record source
and/or domain function (i.e. DAvg("[value]","myTable","mycriteria")) to
populate the report controls.

-Ed
 
P

PC Datasheet

Mark,

Before you go further, you should consider redesigning your Tables. You're
having the problem with this query because the tables are not correct. Assuming
Par1, Par2 and Par3 refer to stocks, your tables needs to be:

TblStock
StockID
StockName

TblStockParValue
StockParValueID
StockID
ParDate
Par

Then you can build a simple totals query based on both of these tables to get
the (Avg, Var, Stdev, ..) values you want for each stock.
 

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


Top