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

Adding up field from a table

P: n/a
good day,

As i have stated before i am a newbie at this game.

I have a table "tblQSPTotals" that has 6 different QSP's on field
"QSPName" and "Project Parts". Under "Project Parts" are total number of
parts for the particular QSP, i now have a form "frmTmManagers" with the
managers of the various departments on and i want to put in a total of
all the QSP parts from the "tblQSPTotals" in a text box on the
frmTmManagers.

Could you please give me suggestions/code that i could use

Thanks in advance

Tempy

*** Sent via Developersdex http://www.developersdex.com ***
Nov 13 '05 #1
Share this Question
Share on Google+
6 Replies


P: n/a
On Thu, 09 Jun 2005 09:13:55 GMT, Tempy <an*******@devdex.com> wrote:

I'm not sure what exactly you're trying to do, but DSum is a function
you can use to add up values.

-Tom.

good day,

As i have stated before i am a newbie at this game.

I have a table "tblQSPTotals" that has 6 different QSP's on field
"QSPName" and "Project Parts". Under "Project Parts" are total number of
parts for the particular QSP, i now have a form "frmTmManagers" with the
managers of the various departments on and i want to put in a total of
all the QSP parts from the "tblQSPTotals" in a text box on the
frmTmManagers.

Could you please give me suggestions/code that i could use

Thanks in advance

Tempy

*** Sent via Developersdex http://www.developersdex.com ***


Nov 13 '05 #2

P: n/a
Hi, I have tried the following in the control Source of the text box:-

=DSum("[Kufner]+[Steyn]+[Remondini]+[Stadler]","tblTotalByrSuppliers")

In Other words i need to add the value of [kufner] (1), the value of
[Steyn](0), [Remondini](0)& [Stadler](1), giving me a total of 2.

I know it is not correct, but maybe this will give you an idea of what i
am trying to achieve, maybe there is a way with code ?

Tempy

*** Sent via Developersdex http://www.developersdex.com ***
Nov 13 '05 #3

P: n/a
Hi I have eventually got it to work with the following:
=DSum("[Kufner]+[Stadler]","tblTotalByrSuppliers")

However if i add any fields with no value in it does not like it, could
somebody please give me some advice

Tempy

*** Sent via Developersdex http://www.developersdex.com ***
Nov 13 '05 #4

P: n/a
Sounds to me like you need to restructure your tables and have a child
table linked to a parent. Then it would be easy to total up without
having to deal with nulls across multiple fields in a DSum.

Nov 13 '05 #5

P: n/a
Hi Ozzone, Excuse the ignorance but i am fairly new at this game, could
you explain ?

Tempy

*** Sent via Developersdex http://www.developersdex.com ***
Nov 13 '05 #6

P: n/a
Sorry i forgot to mention that this table is made from a Query, i do not
know if that makes a difference ?

Tempy

*** Sent via Developersdex http://www.developersdex.com ***
Nov 13 '05 #7

This discussion thread is closed

Replies have been disabled for this discussion.