how to make math equations in a 2003 Access DB

A

Al in JAX

Need help on how to make math equations in a 2003 Access DB.
Here is what I got so far.
Two Tables “Billing†and “Servicesâ€.

In the “Billing†table, I have three fields named
“TimeH2017†data type “number"
“H2017†data type “numberâ€
“SubTolH2017†data type “Currencyâ€

The other table “Services†I have one field named “Charges†and the data
type is “Textâ€

What I would like to do is “TimeH2017†* “Charges†= “SubTolH2017â€

I would like to save the total to the “SubTolH2017†this is where I am
having the most problems (bound) I think.
Any help you can offer I would be grateful.

P.S. I have tried using the “control source†I got it to work once when I
hard coded the numbers but still could not save the sum to the “SubTolH2017â€
field. But I dont want to hard code the date as it will change from time to
time.
 
B

Beetle

In the “Billing†table, I have three fields named
“TimeH2017†data type “number"
“H2017†data type “numberâ€
“SubTolH2017†data type “Currencyâ€

Eliminate the last field as it is a calculated value that should not be
stored in the table. It's possible you may need a Charge field in this
table to record the amount of the charge at the time of each
transaction, but I can't say for sure without knowing more about
your application. Either way you should not have the sub total field.
The other table “Services†I have one field named “Charges†and the data
type is “Textâ€

I would think that the data type of this field should be Currency.
What I would like to do is “TimeH2017†* “Charges†= “SubTolH2017â€

You could do this in a query that includes the TimeH2017 and
Charges fields, plus a calculated field like;

SubTolH2017: [TimeH2017]*[Charges]

You could also do it in the Control Source of an unbound text box
on a form or report;

=[TimeH2017]*[Charges]
 

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