Celebrate National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Matching cells in 2 Excel spreadsheets

Posted on 2011-09-17
2
Medium Priority
?
462 Views
Last Modified: 2012-05-12
I have 2 excel spreadsheets that have the same patient names. In the spreadsheet called “ClarityScheduling_CTRC_Formatted” Column H which is the “StudyID” field is blank and I want to update that column from column C “Study ID” field of the other spreadsheet called “Clarity-CTRC Combination “ by matching the patient name and the date of Appointment together and then copying and pasting the corresponding “Study ID” from column C of the “Clarity-CTRC Combination.xls “ to column H of “ClarityScheduling_CTRC_Formatted.xls”  I have done a couple of examples high light for you to see what I am trying to accomplish with 1173 records. The question is how can I accomplish copy and pasting the correct study IDs to the other spreadsheet.  Attached are the 2 excel spreadsheets. Thanks in advance.
Clarity-CTRC-Combination.xlsx
ClarityScheduling-CTRC-Formatted.xlsx
0
Comment
Question by:Chrisjack001
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 50

Accepted Solution

by:
Ingeborg Hawighorst (Microsoft MVP / EE MVE) earned 2000 total points
ID: 36555572
Hello,

with both workbooks open, enter this formula into cell H2 of the target workbook

=INDEX('[Clarity-CTRC-Combination.xlsx]Combination'!$C$2:$C$1175,MATCH(B2&D2,INDEX('[Clarity-CTRC-Combination.xlsx]Combination'!$A$2:$A$1175&'[Clarity-CTRC-Combination.xlsx]Combination'!$B$2:$B$1175,0),0))

Copy down.

Some cells will show "#N/A" because the combination of name and date is not found in the source file.

To show something other than N/A for these cells, wrap the formula in IFERROR, like this

=IFERROR(INDEX('[Clarity-CTRC-Combination.xlsx]Combination'!$C$2:$C$1175,MATCH(B2&D2,INDEX('[Clarity-CTRC-Combination.xlsx]Combination'!$A$2:$A$1175&'[Clarity-CTRC-Combination.xlsx]Combination'!$B$2:$B$1175,0),0)),"not found")

cheers, teylyn
0
 

Author Closing Comment

by:Chrisjack001
ID: 36555596
Thanks a lot for your prompt help
0

Featured Post

[Webinar] Protection from Cyberattacks

In this session, we’ll dive into the complexities of modern cyber threats and why only multi-vector protection can keep today’s businesses secure through the various stages of a cyberattack, across multiple vectors. Thursday September 14, 2017 10:00 A.M. PDT

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Traditionally, the method to display pictures in Access forms and reports is to first download them from URLs to a folder, record the path in a table and then let the form or report pull the pictures from that folder. But why not let Windows retr…
Cancel future meetings from user mailboxes in Office 365 using Remove-CalendarEvents
Many functions in Excel can make decisions. The most simple of these is the IF function: it returns a value depending on whether a condition you describe is true or false. Once you get the hang of using the IF function, you will find it easier to us…
Although Jacob Bernoulli (1654-1705) has been credited as the creator of "Binomial Distribution Table", Gottfried Leibniz (1646-1716) did his dissertation on the subject in 1666; Leibniz you may recall is the co-inventor of "Calculus" and beat Isaac…

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question