I want to remove duplicate item

0
I retrieve my records from the database and iterate/loop over them one by one. Use the filter by expression list operation in the loop and make constraint like $iteratorObject/Note = $currentObject/Note and $iteratorObject/id != $currentObject/id. But with this method, will delete all the item that have same note. I want to retain one of them.
asked
2 answers
2

Hi Wei,

     For that you need to create a list called NewList which you want to delete, Itererate the list of objects which you have retrieved earlier, then use a find by expression activity In that perform $iteratorObject/Note = $currentObject/Note then add a decision after the list then check FindObject != empty, if the object is empty add to NewList else Add Delete activity to delete the iterater object.

answered
0

Hello Wei Jie Sow,

 

Create a 2list called Object1 and Object2, and in Iteration loop check the condition met or not.

if Condition met add to  Object1 and In 2nd  Iteration check Id is store in object1 or not if you find same id add that in Object2.

After loop delete Object2.

answered