My update query is modifying the IncomingJobID_FK on previous records.
It is taking the IncomingJobID_FK from a comobox on a form and updating that field on my first row when it shouldn't.
It should ONLY update empty fields within rows that contain the IncomingJobID_FK .
Any Ideas?
Code:
UPDATE tblIncomingJobJoin SET tblIncomingJobJoin.Claimed = "-1", tblIncomingJobJoin.InspectorID_FK = [Forms]![tblIncomingJobJoin1]![cboInspectorID_FK], tblIncomingJobJoin.MachineID_FK = [Forms]![tblIncomingJobJoin1]![cboMachineID_FK], tblIncomingJobJoin.CalSphereID_FK = [Forms]![tblIncomingJobJoin1]![cboCalSphereID_FK], tblIncomingJobJoin.Comments = [Forms]![tblIncomingJobJoin1]![txtComments]
WHERE (((tblIncomingJobJoin.InspectorID_FK) Is Null) AND ((tblIncomingJobJoin.MachineID_FK) Is Null) AND ((tblIncomingJobJoin.CalSphereID_FK) Is Null) AND ((tblIncomingJobJoin.IncomingJobID_FK)=[Forms]![tblIncomingJobJoin1]![cboIncomingJobID_FK]));