Excel workbook problem

i have 2 excel workbook … both are different when it comes to column … only one column is common in both workbooks…(i.e mat description column)

mat description in workbook 1 has some 12 line items.
mat description in workbook 2 has some 7 line items.

i want to keep only those line items which are common in both workbooks … how can i do that ?

Hi Check this below link, may be useful.

@poojaskyrathore

  1. Let’s say you have two input DataTables named dt1 and dt2.

  2. And then try below expression to get the required output.

dtOutput = ( From row1 in dt1 Join row2 in dt2 on row1("mat").ToString.Trim.Equals(row2("mat").ToString.Trim) Select dtOutput.Rows.Add({row1("Column1").ToString, row1("Column2").ToString, ...row2("Column1").ToString, row2("Column2").ToString...})).CopyToDataTable

Note: Mention all the required columns from both the tables.

1 Like

Hi @poojaskyrathore ,

Have you Tried using Join Datatable Activity by Selecting Inner as the Join type and The Mat Decription as the Column Names of Both Datatables ?

Assuming that you want to Join based on the Mat Description Column.

can you connect with me … through zoom … so that i can explain you my requirement?

can you connect with me through zoo so that i can explain you my whole requirement ?