Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Compare cells in different worksheets
I have a need to compare column A in a sheet1 to A in sheet2 and if equal
move the value of Column B in sheet2 to Column B in Sheet 1. I have read the vlookup, index, match examples but I am unable to get it to work. Below is some sample data. Any help would be appreciated. Sheet1 Column A Cells 1 thru 11 AAA BBB CCC DDD EEE FFF GGG HHH III JJJ KKK Sheet2 Column A Cells 1 thru 11 Sheet2 Column B Cells 1 thru 11 AAA 1 BBB 2 111 3 222 4 EEE 5 FFF 6 555 7 666 8 JJJ 9 444 10 KKK 11 The result should be (Sheet1) Column A Col B AAA 1 BBB 2 CCC DDD EEE 5 FFF 6 GGG HHH III JJJ 9 KKK 11 -- Mike |
#2
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Compare cells in different worksheets
Try this in B1 of Sheet1
=VLOOKUP(A1,Sheet2!A:B,2,False) and copy down This will give you the values from Col B of Sheet2 where Col A matches with A1 and #N/A where it does not. To suppress the #N/A use this =IF(ISNA(VLOOKUP(A1,Sheet2!A:B,2,False)),"",VLOOKU P(A1,Sheet2!A:B,2,False)) "Mike" wrote: I have a need to compare column A in a sheet1 to A in sheet2 and if equal move the value of Column B in sheet2 to Column B in Sheet 1. I have read the vlookup, index, match examples but I am unable to get it to work. Below is some sample data. Any help would be appreciated. Sheet1 Column A Cells 1 thru 11 AAA BBB CCC DDD EEE FFF GGG HHH III JJJ KKK Sheet2 Column A Cells 1 thru 11 Sheet2 Column B Cells 1 thru 11 AAA 1 BBB 2 111 3 222 4 EEE 5 FFF 6 555 7 666 8 JJJ 9 444 10 KKK 11 The result should be (Sheet1) Column A Col B AAA 1 BBB 2 CCC DDD EEE 5 FFF 6 GGG HHH III JJJ 9 KKK 11 -- Mike |
#3
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Compare cells in different worksheets
Sheeloo,
Thanks, your solution worked great. I had a similar one but for some reason it did not work, I will need to compare the two. Thanks again for the help. -- Mike "Sheeloo" wrote: Try this in B1 of Sheet1 =VLOOKUP(A1,Sheet2!A:B,2,False) and copy down This will give you the values from Col B of Sheet2 where Col A matches with A1 and #N/A where it does not. To suppress the #N/A use this =IF(ISNA(VLOOKUP(A1,Sheet2!A:B,2,False)),"",VLOOKU P(A1,Sheet2!A:B,2,False)) "Mike" wrote: I have a need to compare column A in a sheet1 to A in sheet2 and if equal move the value of Column B in sheet2 to Column B in Sheet 1. I have read the vlookup, index, match examples but I am unable to get it to work. Below is some sample data. Any help would be appreciated. Sheet1 Column A Cells 1 thru 11 AAA BBB CCC DDD EEE FFF GGG HHH III JJJ KKK Sheet2 Column A Cells 1 thru 11 Sheet2 Column B Cells 1 thru 11 AAA 1 BBB 2 111 3 222 4 EEE 5 FFF 6 555 7 666 8 JJJ 9 444 10 KKK 11 The result should be (Sheet1) Column A Col B AAA 1 BBB 2 CCC DDD EEE 5 FFF 6 GGG HHH III JJJ 9 KKK 11 -- Mike |
#4
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Compare cells in different worksheets
You are most welcome.
I am happy that it worked out for you. -Sheeloo |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Need to compare 2 worksheets... | Excel Discussion (Misc queries) | |||
compare 2 worksheets for simliar cells and then comb into one work | Excel Discussion (Misc queries) | |||
compare worksheets | Excel Discussion (Misc queries) | |||
How do I compare cells and if FALSE compare to next cell in EXCEL | Excel Worksheet Functions | |||
How do I compare data in two worksheets to find matching cells? | Excel Discussion (Misc queries) |