Match variable to table column1 and output column2 as variable

So I’m pulling a variable (let’s call it vehinfo1) from one application and need to input that data into a second application. However, the terminology/wording used in the second application is case sensitive and differs from the first application.

What I need to do is: Compare vehinfo1 variable to Column1 in a table or Excel spreadsheet and when I find a match, I need to assign the matching term from Column2 (which will always be in the same row) to a second variable (let’s call it vehinfo2) and input that into the second application.


Multiple ALL OVER

So in the above example, if vehinfo1 was compared to COLUMN1 and matched “Front” then I would need to assign vehinfo2 to “FRONT END”.

(I can very easily extract and input the variables once I have them, however I just cannot figure out how to compare and assign the values using a table or Excel spreadsheet. I’ve looked through a vast number of topics but they all have solutions for comparing or amending spreadsheets that are not relevant to my situation)

Buddy @PhilDev

Welcome to uipath community buddy
–use read range activity to read the excel data and store it to variable of type datatable
–then use a for each row loop and pass the above obtained variable to the for each row loop
–inside the loop use a if condition like this

if this conditions get matched it will go to THEN part of if condition where you can get or assign the value to the column2 like this
if to assign, row(“Columnname”) = “The value you want to assign”
if to get, row(“Columnname”) = “The value you want to get”

Kindly try this and let know buddy @PhilDev

1 Like

Thank you so much @Palaniyappan - this has provided a great solution. I was just thinking along the wrong lines before.

1 Like

Cheers Buddy @PhilDev

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