Skip to Content
Aug 22, 2017 at 02:40 PM

how to remove duplicate record in my Custom Bo?


Hi sap,

BYD requirement;-1)I have to pull extension Bo fields to Custom Bo.

2)I created successfully and I written logics in Beforesave and after modify, but I am getting duplication records in custom bo?

3)After that, I restricted using this code.

foreach (var a in this)


if (a.IsSet())


var HrLettersQry = HrLetters.QueryByElements;

var Creass = HrLettersQry.CreateSelectionParams();

Creass.Add(HrLettersQry.A_EMPID.content, "I", "EQ", a.ID.content);

var res = HrLettersQry.Execute(Creass);

if (res.Count() == 0)


itemData.EMPID.content = a.ID.content;


4)when I am updating the data in standard bo that data is not reflecting my custom BO.And it's saving old data not new data.

Any one please give me how to update the values as well as how to restrict the duplicate coloumns.

please give me suggestion..