Subform won't loop on update records

Subform won't loop on update records

Hey guys,

I've been stuck for about four hours on this:

I have a master entry form (Form A) that is comprised of a subform (Class_Attendance), The data entered into the subform updates two other forms (Forms Training Dossier & Training Expiration). 

Upon submission of Form A, the following occurs:

(1) Records are 'added' to Training Dossier, and
(2) Records are 'updated' in Training Expiration

The code that supports the addition works fine:

for each row in input.Class_Attendance
{
    insert into Training_Dossier
    [
        Added_User = zoho.loginuser
        Employee_Name = row.Employee_Entry
        Roster = input.Roster
        SSN = row.SSN_4
        Training = input.Training
        Training_Date = row.Training_Date
    ]
}

The code that supports the update does not loop. The first record in the subform is updated, but the remaining records are not:

update  =  Training_Expiration  [SSN == input.Class_Attendance.SSN_4];
for each row in input.Class_Attendance
{
    if (input.Training  ==  2507236000000875055)
    {
        update.Awareness = row.Expiration_Date;
    }
}

input,Training is a lookup field.

Any suggestions on how to make the subform loop on the update piece? It works fine for the addition....

Thanks for any support,

CM