Hi all,Code:DoCmd.SetWarnings False DoCmd.RunSQL "INSERT INTO Person2AddressTbl (PersonID, AddressID) " & _ "VALUES (" & CboPerson & ", " & AddressID & ")" DoCmd.SetWarnings True
I have a many - many table that I want to insert into by SQL Statement above Which does work, however, is there a way to make this not insert if PersonID and the AddressID all ready exist in the same record on the table? Case being this is on a onclick of the close button so when I hit close, it inserts into my Person2AddressTbl, but if the record is not new, then I don't want a duplicate if that makes sense?