unique constraints on update should take into account all records