totaling fields

A

ARHGUY

I have a table with multiple fields i.e. Hourly Rate, Personnel Trained, and
Hours Trained. I have an additional field were I want to save the dollar
amount(value) of this training provided easy enough to multiply, and have the
control source textbox on my form with the total by record. I want to
populate that result back into the table by record. Help!
 
A

Allen Browne

See:
Calculated fields
at:
http://allenbrowne.com/casu-14.html

The article explains that you must not store the calculated value, unless
there are cases where that calcuation would be incorrect (e.g. discounted
totals.)

It also explains how to use the AfterUpdate event of the dependent controls
to write the calculation.

If you have a bunch of existing records, use an Update query to write the
calcuation for those.
 
R

Rick B

You don't. You should not store a calculated result in a table. What
happens to that calculated result if you find that one of the underlying
numbers was typed wrong and needs to be corrected?

Instead, just perform the calculation in your forms, reports, and queries
when you need it. No need to store the figure.
 
A

ARHGUY

Ok, Now to the new issue and the reason I'm trying to do this. I need to
build a query that includes my cost avoidance table, but need that total for
training hours, hourly rate and personnel trained that is calculated on the
form. How do I include that result in a query based on the table?
 

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