Addition Query

scottmvinovrski

Registered User.
Local time
Yesterday, 16:30
Joined
Nov 8, 2006
Messages
43
Hey everyone,
I have a form that acts as a survey asking 11 questions total. Each field in my table is called material1, material2, ect. I have a total field in my table that I would like to be the sum and was told that I have to do this through a query. My only problem is when i query it only gives me the sum of Question 1, 2 ect and does total them all. Can someone nudge me in the right direction as I am relatively new to this. i appreciate everyones help on this forum.
 
You need to add a calculated field. Eg:
MyTotal:material1+material2+...

However the fact that you have these names suggests that your design is not normalised. Instead of having one field for each value, you should have one record in an associated table so that when complete you have 11 records. You can then use a totals query to get what you want.
 
Neilg,
I was able to create a textbox that the control=Material1+material2, ect and it changes everytime i enter a different value however that value that is in the textbox I cant seem to have to going to my Total Score box? That is my main problem
 
Each box has an answer of 3-Strongly agree, 2-Agree, and 1 Disagree. The totals box adds the 3 or 2 or 1 from each box. My problem was having a total score box bound to my table.
 
scottmvinovrski said:
Each box has an answer of 3-Strongly agree, 2-Agree, and 1 Disagree. The totals box adds the 3 or 2 or 1 from each box. My problem was having a total score box bound to my table.
Hi
You should not store totals in a table. It goes against the rules of relational database design. You can always calculate the total whenever you need it - no need to store them.
Stopher
 
Thank you for clearing that up. Ok that makes sence I can always total them up in a report.
 

Users who are viewing this thread

Back
Top Bottom