Output all the Matched values from Matching file

Dear Master,
Greetings !!
I am stuck with one problem, wherein i have
Excel A- Input File
Excel B - Matching File.

i was trying to Match Excel A with Excel B with Column “Country”.
if Match found i need an output of all the matched rows from Excel B.
e.g. if country IN has 2 rows in Matching file “Excel B” then i need those two rows in output file.

i was trying with if activity. but i am only getting one row from excel B.
request your assistance on the same.
Thank you so much for your support.

Excel A.xlsx (11.5 KB) Excel B.xlsx (9.8 KB)

Hi @Sonia_012
Check this workflow
sample workflow.zip (2.0 MB)

Mark it as solution if it resolves your query
Regards
Nived N
Happy Automation

1 Like

Hi Nived
@NIVED_NAMBIAR
Thank you so much…

(From r1 In dt1.AsEnumerable
From r2 In dt2.AsEnumerable

can you please explain what is r1 and r2

and will i be able to use this if i need to compare with multiple column.

for example if there is no match found from country then i should try to match with pin.
i have attached the updated excel…
please help
Excel A.xlsx (11.5 KB) Excel B.xlsx (9.9 KB)

Hi @Sonia_012

Check this updated workflow
sample workflow.zip (2.0 MB)

r1 and r2 signifies the row

Regards
Nived N
Happy Automation

hi @NIVED_NAMBIAR
one small query.
i want to write this in dynamic way… r1 and r2
can i use column name instead of r1 and r2
because this country or pin can be anywhere in excel

please advise

U can use r1(ColumnName) to get the column value from each row @Sonia_012

1 Like

Did it resolves ur query @Sonia_012

i am checking… actually i am using config file so i have to take all the values from config… this columnName and everything from config
m trying

U can put r1(inconfig(keyname)) to get the coloumn value @Sonia_012

this is what i am trying to do… using config… and i after matching i need all the matched values from excelB

config.xlsx (9.3 KB) Excel A.xlsx (11.6 KB) Excel B.xlsx (10.2 KB)

any thoughts :sob: @NIVED_NAMBIAR

U can apply this in my code itself @Sonia_012 using or condition

I already sent u the workflow in my earlier reply

image_2021-02-17_192218
if you are looking this output result only match record please check workflowSonia forum match two excel and paiste match record.zip (33.0 KB)

2 Likes

checking :smiling_face_with_three_hearts:

hi @Aleem_Khan

thank you so much for your effort…

@NIVED_NAMBIAR has shared this earlier with me .
actually m trying to use config file which i have shared with Nived as well…
he has provided me a solution i am trying that…

welcome please mark as solution I really appreciate

hi @NIVED_NAMBIAR
one question is that possible to get “Name” from Excel A + the row items of excel B.
for example the WF which u shared yesterday in output…
please advise

Capture