I have a merged data table which I compare with another datatable (A_B_C) by using LINQ activity in order to have only unique rows as outcome, my code is:
Certsdone - my merged DT
unique row (enumarable list) my uniqe rows = A_B_C_completed.AsEnumerable().Where(Function(raportRow) Not certs_datatable.AsEnumerable().Any(Function(x) x(“Kolumna1”).ToString() = raportRow(“Kolumna1”).ToString() And x(“Kolumna2”).ToString() = raportRow(“Kolumna2”).ToString() And x(“Kolumna3”).ToString() = raportRow(“Kolumna3”).ToString()))
and my question is: how do I later update my CertsDone with unique values? so the values that are saved in my variable uniquerows that I would like to append to Certs DT any ideas?
(From d In A_B_C_completed.AsEnumerable()
Let lcs = arrColSet.Select(Function (x) d(x).ToString.Trim)
Let chk = certs_datatable.AsEnumerable().Any(Function (d2) arrColSet.Select(Function (x2) d2(x2).ToString.Trim).SequenceEqual(lcs))
Where Not chk
Select r = d)