Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I need to compare employee information between 2 lists and spit out
mismatches. So, for instance, I have a spreadsheet with a column of employee IDs. The second column is the employee department numbers. We know the information on this spreadsheet is accurate. There's a second spreadsheet with the same columns, however we need to check this spreadsheet against the first because we aren't sure it's correct. So I need a function that will look at cell A1 in the first spreadsheet, find the corresponding row in the second spreadsheet and compare the corresponding department number values to see if they're the same. I think this is a combination of VLOOKUP and IF functions, I just can't figure out how to refer to the row numbers. Any ideas? Thanks Rebecca |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Just to make sure I am understanding correctly:
You have two spreadsheets. Both have two columns, name and department. The first spreadsheet contains the correct name-department list. The second spreadsheet is questionable. You want to find a value from the first spreadsheet on the second spreadsheet and see if the corresponding departments match. Assuming the Name is the column A, the department is in column B, put this formula in column C: =IF(VLOOKUP(A2,Second Spreadsheet A:B,2,0)=B2,"Match","Error") So you are looking up the name from the first spreadsheet (A2) on the second spreadsheet and pulling back the second column (department) from the second spreadsheet and comparing it to the department on the first spreadsheet (=B2). If they match, Match, if not Error. That got a little wordy... post back and let us know how it turned out... -- Regards, PJ Please rate this post using the vote buttons if it was helpful. "rebecca" wrote: I need to compare employee information between 2 lists and spit out mismatches. So, for instance, I have a spreadsheet with a column of employee IDs. The second column is the employee department numbers. We know the information on this spreadsheet is accurate. There's a second spreadsheet with the same columns, however we need to check this spreadsheet against the first because we aren't sure it's correct. So I need a function that will look at cell A1 in the first spreadsheet, find the corresponding row in the second spreadsheet and compare the corresponding department number values to see if they're the same. I think this is a combination of VLOOKUP and IF functions, I just can't figure out how to refer to the row numbers. Any ideas? Thanks Rebecca |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
On May 8, 3:01*pm, PJFry wrote:
Just to make sure I am understanding correctly: You have two spreadsheets. *Both have two columns, name and department. *The first spreadsheet contains the correct name-department list. *The second spreadsheet is questionable. *You want to find a value from the first spreadsheet on the second spreadsheet and see if the corresponding departments match. * Assuming the Name is the column A, the department is in column B, put this formula in column C: =IF(VLOOKUP(A2,Second Spreadsheet A:B,2,0)=B2,"Match","Error") So you are looking up the name from the first spreadsheet (A2) on the second spreadsheet and pulling back the second column (department) from the second spreadsheet and comparing it to the department on the first spreadsheet (=B2). *If they match, Match, if not Error. That got a little wordy... post back and let us know how it turned out... -- Regards, PJ Please rate this post using the vote buttons if it was helpful. "rebecca" wrote: I need to compare employee information between 2 lists and spit out mismatches. So, for instance, I have a spreadsheet with a column of employee IDs. The second column is the employee department numbers. We know the information on this spreadsheet is accurate. There's a second spreadsheet with the same columns, however we need to check this spreadsheet against the first because we aren't sure it's correct. So I need a function that will look at cell A1 in the first spreadsheet, find the corresponding row in the second spreadsheet and compare the corresponding department number values to see if they're the same. I think this is a combination of VLOOKUP and IF functions, I just can't figure out how to refer to the row numbers. Any ideas? Thanks Rebecca- Hide quoted text - - Show quoted text - Worked great -- thank you PJ! |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
No problem.
There should be a 'Did this answer your question' button at the bottom of your form. Go ahead and click 'Yes'. -- Regards, PJ Please rate this post using the vote buttons if it was helpful. "rebecca" wrote: On May 8, 3:01 pm, PJFry wrote: Just to make sure I am understanding correctly: You have two spreadsheets. Both have two columns, name and department. The first spreadsheet contains the correct name-department list. The second spreadsheet is questionable. You want to find a value from the first spreadsheet on the second spreadsheet and see if the corresponding departments match. Assuming the Name is the column A, the department is in column B, put this formula in column C: =IF(VLOOKUP(A2,Second Spreadsheet A:B,2,0)=B2,"Match","Error") So you are looking up the name from the first spreadsheet (A2) on the second spreadsheet and pulling back the second column (department) from the second spreadsheet and comparing it to the department on the first spreadsheet (=B2). If they match, Match, if not Error. That got a little wordy... post back and let us know how it turned out... -- Regards, PJ Please rate this post using the vote buttons if it was helpful. "rebecca" wrote: I need to compare employee information between 2 lists and spit out mismatches. So, for instance, I have a spreadsheet with a column of employee IDs. The second column is the employee department numbers. We know the information on this spreadsheet is accurate. There's a second spreadsheet with the same columns, however we need to check this spreadsheet against the first because we aren't sure it's correct. So I need a function that will look at cell A1 in the first spreadsheet, find the corresponding row in the second spreadsheet and compare the corresponding department number values to see if they're the same. I think this is a combination of VLOOKUP and IF functions, I just can't figure out how to refer to the row numbers. Any ideas? Thanks Rebecca- Hide quoted text - - Show quoted text - Worked great -- thank you PJ! |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Comparing pairs of cells in four columns | Excel Discussion (Misc queries) | |||
Sum product of many pairs of columns | Excel Worksheet Functions | |||
merge pairs of columns | Excel Programming | |||
Removing Duplicate Pairs(2 Columns) | Excel Discussion (Misc queries) | |||
Remove Duplicate Pairs(2 Columns) | Excel Programming |