Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

inserting data into db ON TOP of a previous numerical value

Status
Not open for further replies.

NeilBelgium

IS-IT--Management
Sep 18, 2001
87
BE
dear all,

how to add a value from a form into an existing numerical field?

I'm designing a db to record ratings for employees, which may be given by several of their colleagues.
I'm using asp/access/iis, and also have UltraDev as I believe this will take a lot of the time out of the process.

I'm stuck, though.
say I have a field called Question1, and I have a form that can insert into this field. Fine. But what happens when another person enters a score. What i need is a field Question1average, and a method of adding the second persons input to the first, and so on, instead of overwriting.

Presumably some method of calling the original value, adding this to the second value in an asp, and then putting both together and back into the db.

But how? my asp is limited, and I need to know how to do this.

much appreciated, neil
 
There is more to this than simply retiieving the old value and 'averaging' it. What happens when the third evaluation occurs? Using your method, the aparent weight of the fist two 'evaluations' is diluted. What if a previous evaluator wants to change their evaluation? Or perhaps they would provide a differnt evaluation at some other time (period)?

You will not find an simple answer to these issues.

MichaelRed
m.red@att.net

There is never time to do it right but there is always time to do it over
 
Averages, etc., should not be "put in the db" - they should be computed in queries and reports.
 
many thanks for the input. Someone has suggested to me I need to go back another step and start by organising my tables.

So, how do i organize the following:

fields:
name

for each "name" the following data is being collected:
results (one numerical value) of questions 1-5 from peers
results of questions 1-5 from subordinates
results of questions 1-5 from customers
results of questions 1-5 from bosses
total for this section (now I know to use a query!!)

This needs repeating for questions 6-10, 11-15, 16-20.

very messy, I know! thanks, neil
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top