Error when saving a Business Object: An item with the same key has already been added

Version 1


    This error can be raised in two cases:

    1.- There is a duplicated record
    2.- There are two fields defined with the same name, this can happen in the Extended Business Objects, when a field is created in the main table and then a field with the same name is created in one of the extended tables.


    For the first case, check the indexes for identifying the key fields, and look for a duplicated record. For example, for the Employee, we could use the following query:

    select count(recid) as total, recid, contactid from employee
    group by recid, contactid
    having count(recid) > 1

    For the second case, we would have to review manually the customized fields and check that there are not fields with the same name or display name created in the main and in the extended tables.