L
Laurel
I have code which updates the database in two ways. Both times, if I put
?Currentdb.RecordsAffected in the immediate window just after the statement
is completed, the value is 0. If I look at the tables being updated, both
statements worked. In one a row is deleted, and in the other a row is added
in. I use two methods:
CurrentDb.Execute "CurrentDb.Execute "DELETE * FROM tblClassSummaryTemp
WHERE student_id <> -1;"
With irstClassSummary
.AddNew
!Student_ID = 27
!Total = txtTotal
!Bonus_Days = txtBonus_Days
!Level_Fines = txtLevelFines
!Safety = txtSafety
!Homework = txtHomework
.Update
End With
If RecordsAffected isn't the right approach, how can I test that my updates
to the database are successful?
?Currentdb.RecordsAffected in the immediate window just after the statement
is completed, the value is 0. If I look at the tables being updated, both
statements worked. In one a row is deleted, and in the other a row is added
in. I use two methods:
CurrentDb.Execute "CurrentDb.Execute "DELETE * FROM tblClassSummaryTemp
WHERE student_id <> -1;"
With irstClassSummary
.AddNew
!Student_ID = 27
!Total = txtTotal
!Bonus_Days = txtBonus_Days
!Level_Fines = txtLevelFines
!Safety = txtSafety
!Homework = txtHomework
.Update
End With
If RecordsAffected isn't the right approach, how can I test that my updates
to the database are successful?