Two DT's

Hi All,

I have two DT
Book1 - where I have column with name, position and manageemployee


Book2 - where I have column with name and Role
Capturebook2
My point is to compare those DT’s and if I have in Book2 the same name as I have in Book1, I want to take the Role and write into the next free column in corresponding row in Book1
results like below

THX

HI @niteckam Try this - (From a In DT2.AsEnumerable() Join b In DT1.AsEnumerable() On a(“Name”).ToString() Equals b(“Name”).ToString() Select a).CopyToDataTable()

Thanks,
AK

Do it directly in Excel

Hi @AnandKumar26

Can you please try to put it into small workflow I was trying your suggestion but it does not work as I suppose it will
Book1.xlsx (9.0 KB) Book2.xlsx (8.7 KB)

Hi @c.ciprian
I can not do those calculation in excel. It must be coding

Hi @niteckam - Please see attached

ExcelDT.xaml (5.2 KB)

Thanks,
AK

HI,
@AnandKumar26
The output is not the one I expected
I need to have finally DT as below

Hi, This is almost 80% done. Need to debug and see where the issue in writing the “Role”

Thanks,
AK

ExcelDT.xaml (13.1 KB)

Hi @AnandKumar26
I have problem with Column, it gives my the wright number but I do not have output from variable ColumnExactIndex

Hi @niteckam - This has been resolved now.

Please see attached.

Thanks,
AKExcelDT.xaml (18.1 KB)

1 Like

Hi @niteckam - If the attached workflow works fine for you as expected then please mark it as Solution or Resolved to close the query.

Thanks,
AK

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