Matching Duplicate Rows using LINQ

Good day fellow RPA Devs,

I need help on how to match duplicates rows.

I have two input data tables

And this is the expected output

I need to match duplicates. If it doesn’t have a match the phone number value will be returned as “#N/A”

Anyone knows how can I implement this in LINQ?
Any help would be appreciated.

Best Regards,
Anthony Jr.

The matching column is the “TRACE-INVOICE”

Hi you can use a left join with this actually rather than using linq.

just for reference you can use the following to get only duplicate records
(From d In io_dt_KKBAInput_file
Group d By k1=d(“RefNo”).toString.Trim,k2=d(“SVTD_AMT”).toString.Trim Into grp=Group
Where grp.Count > 1
Select grp.tolist).SelectMany(Function (x) x).CopyToDatatable