How to compare datatable and add/copy related content in 1st data table

Hello ,

I have 2 data table - DT1 and DT2
I need to find if value in currentrow(0) in DT1 is available in DT2’s anywhere in 1st column if not found I need to add in DT1- not found and if found copy further column from DT2 and paste in DT1’s 4th and 5th column.
DT1.xlsx (9.8 KB)
DT2.xlsx (9.0 KB)

Can you share the input and expected output

Hi @Dinesh_Guptil , thanks for reply. Attached the sheets ,DT1 and DT2 are 2 excels
output I want in DT1 and in same sheet only …


Refer this (18.1 KB)

1 Like

Hi @8b6861dc5e0c9f7008548ca66

For DT1
Read Range

For DT2
Read Range

Use For Each Row

Use For Each Row (Nested For Each)

If VarInDT1=VarInDT2
"Match Found"
Use Break Activity (Exit the inner loop since a match is found)

"Value is not found in DT2"
Use Add Data Row Actvity in DT1 (add it to DT1 with placeholders for 4th and 5th columns)
1 Like

Hi @8b6861dc5e0c9f7008548ca66

Please find the attached Xaml File (1.7 KB)


Thanks @Shiva_Nikhil , it’s working as expected .

1 Like

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