Duplicate data



Remove duplicate data from Excel
Tried Many Ways not getting result
Please Help

Hi,

Can you share your input and expected output as file?

Regards,

Hey

try with

dtResult.DefaultView.ToTable(true,"yourColumn1", "yourColumn2", "etc..")

Regards



(30&31) ARE INPUT AND 29 IS OUTPUT

HI,

Can you attach the xlsx file(s)?

Regards,

RPA - Copy (3) - Copy.xlsx (11.4 KB)

HI,

Can you try the following sample?

 dt = dt.AsEnumerable.GroupBy(Function(r) r("reference").ToString).Select(Function(g) dt.Clone.LoadDataRow({g.Key,g.First().Item("Date"),g.First().Item("Description"),g.First().Item("Amount").ToString,if(g.count>1,g.Last().Item("Amount"),0)},False)).CopyToDataTable

Sample20230210-6L.zip (11.4 KB)

Regards,

THANK YOU
THANK YOU

in this i am getting the result but some of my rows is not showing
last 12 rows are not coming up

Have you tried modern UI Excel activity Remove Duplicates? if not give a try. Reference - https://docs.uipath.com/activities/docs/remove-duplicates-x. This also provides option to compare the column to remove the duplicate row.

Regards
Balram

Hi,

Can you elaborate? the above result seems same as your expected result as the following.

Regards,

RPA - Copy (3) - Copy.xlsx (11.8 KB)
As you see there are other extra row in this
AND If i want to remove 0 from TVS Column then

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.