Copying the excel column data to another excel sheet column with some conditions applied

Hi All,
I need a help guys.I have one excel sheet where id,Name and salary column is made in which there is some data available in each column except salary column which is to be blank for the time being.
I have another excel sheet where In column Id the same data as in Data 1 is available but in random order and in salary column there are some values for each id.
what i need to do is to retrieve the salary credentials from Data 2 and put it into the Data 1 and the amount should be same for the id given in Data 2 sheet.

I am attaching the sheet
Data1.xlsx (7.9 KB)

Data2.xlsx (7.9 KB)


1)Read the Data2 as Datatable.
2)Iterate a loop for number of row in Data1
a)find the ID value(Read cell) in Data1
b)Iterate the loop for Data2-ID column(datatable) to find the ID value
c)You can read the Salary (Datatable)
d)Use Write cell to write the salary in Data1


Simple VLookup and auto fill range will do that trick @Ani008,

Let me know if you are interested in using the VLookup funtionality :slight_smile:


By applying VLOOKUP we can achieve it, Please find the working for reference,
VLOOKUP.xaml (8.1 KB)
Hope this will help you.

Suresh J