By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
445,705 Members | 1,829 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 445,705 IT Pros & Developers. It's quick & easy.

General Computations

P: 64
I am createing a sales tracking program. Is there any advnatage to haveing math computed at the table level...or is it better to do the math on the forms and reports?

Thanks

-TomB
Aug 13 '08 #1
Share this Question
Share on Google+
3 Replies


100+
P: 167
General rule with databases is that calculations should be done at the moment we use data. This way we ensure to have only newest 'results'.
Also we save space (memory) by storing only original data from which we can make calculations the moment we need them.

We can use calculations to update the original data and that is OK, but generally we store only input data.

If by 'table level computations' you meant queries then YES it's usualy better/faster to make calculations in queries than on forms or reports.
Aug 13 '08 #2

missinglinq
Expert 2.5K+
P: 3,532
And If by 'table level computations' you meant "in tables" you can't! The closest you can come is, as has been suggested, in queries. The advantage of doing it in a query is that you only have to do it once, instead of every time you need the results. In the Query Grid you would create a calculated field. Where the Field name goes, you'd do something like this:

Area: [Length]*[Width]

Then in forms or reports, use Area as the Control Source for your textboxes.

Linq ;0)>
Aug 13 '08 #3

P: 64
thanks...with the resulting responses...I knew that the query was the most efficient way to get calculations...but I had forgotten that I knew.

Thanks

TomB
Aug 13 '08 #4

Post your reply

Sign in to post your reply or Sign up for a free account.