inserting from one form, then updating from another [message #81861] |
Thu, 27 March 2003 07:26  |
kim
Messages: 116 Registered: December 2001
|
Senior Member |
|
|
hi everyone,
here is what i am trying to do: first i have the user enter some data for a specific date on the first form. then the user presses a button which commits the form, inserting a new date with entered data. next if they would like, they can press a button that opens up another form. i bring the date through to the next form with a global variable and they can enter more data if they would like and commit again... only this time, i need to update the record for that date. EXCEPT when i am trying to do this, the form is still trying to insert a record. the first record is updating, and a second record is also being created. what am i doing wrong, and how can i stop it from inserting twice so that it only updates on the second form?
all i am doing on the second form is this...
update mn_rawdata
set upa_tot_moist = :hdr.upa_tot_moist,
upa_vol_matter = :hdr.upa_vol_matter
where rdate = :key.rdate
and matcode = :key.matcode
and lotno = :key.lotno;
commit;
thanks!
|
|
|
|
|