Check for repeat values in Datatable & delete in place

Hello, I have been trying to take an excel datatable and compare the values in a column, thereafter finding any repeat values in the column and deleting it in place. An example will be in the screenshot attached.image ![ss|404x415]

I have tried a long winded method, but i am stuck now.
That is to go into the DatatableColumn -> for each row -> get the value of each cell and store it in an array_variable -> for each array_value, check if there is any duplicates in the array -> replace the value with something like " " -> rewrite it to the file.

I am stuck at the part in bold. May i know if there is anyway to do this?
Also appreciate if there is a complete shortcut to this

Hi,

Have you tried using Remove Duplicates activity?

1 Like

@cwl8
Give a try on
YourDataTableVar.AsEnumerable.Select(Function ( r ) r(YourColumnNameOrIndex).toString).Distinct().ToArray

Use this within an assign activity and get returned an array of Strings