Remove only particular duplicate rows and remians take string upto duplicate rows

Its my input data:

image

I have to remove duplicate first two cloumns and third column take string upto duplicate rows

Output:
image

Hi,

Can you try the following sample?

dt = dt.AsEnumerable.GroupBy(Function(r) Tuple.Create(r("CR_NO").ToString,r("Overall_Status").ToString)).Select(Function(g) dt.Clone.LoadDataRow({g.Key.Item1,g.Key.Item2,String.Join(",",g.Select(Function(r) r("Details").ToString))},False)).CopyToDataTable()

Sample20230721-3L.zip (8.4 KB)

Regards,

Thank You @Yoichi , it’s working fine :star_struck:

1 Like

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