Sum Query into report

  • Thread starter Thread starter James
  • Start date Start date
J

James

I have a simple database with 1 table which includes 3
fields called Kitchen total, restaurant total, Total of
Kit & Rest. I have created a query that displays these
totals ready for a report. On the report, I want to be
able to sum up each total so that I have a total of each
column. My only problem is, when I print the report - it
totals each item of the column individually and is not
giving a grand total. I hope this makes sense. Basically I
am going wrong with sum command on my report design. It
may be in the wrong place etc. Hope someone can help.
Thanks
 
James,

If you could provide a sample of the expression you are using for the Grand
Total, it would be helpful.


--
Allan Thompson
APT Associates/ FieldScope LLC
MS Office Automation / Measurement and Reporting Systems
www.fieldscope.com
860.242.4184
 
James

One approach would be to create a new control in your report's "Footer"
section, and set its value to something like (actual syntax may vary):
=Sum([YourControlHoldingKitchenTotalDetails])

This assumes you have your three fields (controls) in the Detail section of
the report, so the footer can sum over all "detail" records.

If the only thing you need in your report is the grand total in each
category, use a Totals query to get those, then build your report based on
the Totals query, not the table.

By the way, if you have a field which is the (calculated) total of two other
fields, you will (probably) find yourself in trouble at some point. First,
there's no need to store calculated values when you can use the speed of
your computer to much more quickly re-calc the values than look them up on
the hard drive. Second, storing calculated values means you need to keep
all related fields in "sync", in case there's a change made to any of them.
And a third, minor point is why waste storage space.
 
Thanks for this info. I have created another query from my
original query and now I can get the correct views on the
report. Cheers.
 
Back
Top