You talk about fields, but your data is coming from a form, thus controls, no?
You'd have to use a IF Statement to compare the value and act accordingly, so something along the lines of
Dim db As DAO.Database
Set db = CurrentDb
If Me!textbox1.Text = Me!textbox2.Text Then
db.Execute "INSERT INTO table1(field1, field2, field3) " & _
"VALUES ('" & Me!Combo1 & "', '" & Me!textbox1.Text & "', '" & Me!textbox2.Text & "');"
If db.RecordsAffected <> 0 Then
MsgBox "Record Saved !!!", vbInformation, "Success"
End If
End If
Set db = Nothing
Daniel Pineault, 2010-2018 Microsoft MVP
Professional Support: http://www.cardaconsultants.com
MS Access Tips and Code Samples: http://www.devhut.net