Get Value of Second Column each row

Hello,

I have two excel files lets say TABLE 1 and TABLE 2.

Table 1 has 7 rows and 2 columns
Table 2 has 18 rows and 1 column

The requirement is as followed.

I have to match all 18 rows of Table 2 with Table 1 all rows. E.g. Table 2 has Mumbai so if table 1 has Mumbai it will give the value True. Now in the Table 1 which has 7 rows and 2 columns in the second column it has MU for Mumbai. so I want to print that value for MU.

so what I am trying to do is for each iteration Table 2 will try to find the value with Table 1 so it will have 18 iterations now lets say for 3rd iteration it finds the value in table 1 and prints the value True so for that occurrence I need to print the value in Table 1 column 2 at whatever the row number the result is found.

I hope I was clear to explain the task. My focus is just to get the second column value for the found row value. all other work is done like how to match the value ans all.

Please try to help me with this.

Thanks

To get matched records use following xaml

Get Unique Values.xaml (5.4 KB)

So output of this xaml is datatable(dt1),
So if you want 1st value of 2nd column
You could use something like
dt1.rows(0).item(1) or dt1.rows(0).item(“columnName”)

1 Like