Take care of duplicate entries on inserts