Solved

Copying data from one Excel 2007 spreadsheet to another when destination spreadsheet may not contain all same rows

Posted on 2014-03-12
6
296 Views
Last Modified: 2014-03-12
I have two spreadsheets of school names.  One spreadsheet contains 11 columns without headers.  Column K contains data that needs to be copied to the other spreadsheet.

The destination spreadsheet also has 11 columns, but with headers.  The information from Column K of spreadsheet #1 (High-Schools-2014-with-PAAK) needs to be copied to spreadsheet #2 (high-schools-Destination-File).  However, the information in each cell in column K must match with the correct school name.  

Not every school in the destination file appears in the first file, therefore would not have data copied over to column K.  There may be schools in spreadsheet #1 that do not appear in the destination file.  

I need some type of formula that will look at the school name in Column A, copy the data in Column K, and paste into the proper cell in the destination spreadsheet corresponding to the same school name.  

Is this possible?
High-Schools-2014-with-PAAK-code.xlsx
high-schools-Destination-File.xlsx
0
Comment
Question by:gsfc
[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
  • 4
6 Comments
 
LVL 31

Expert Comment

by:gowflow
ID: 39924329

I need some type of formula that will look at the school name in Column A, copy the data in Column K, and paste into the proper cell in the destination spreadsheet corresponding to the same school name.  

You need this as formula ? Could VBA be an option ?
gowflow
0
 

Author Comment

by:gsfc
ID: 39924391
I'm not familiar with VBA.  If this is something you can provide to me, perhaps I can sk another in our department to assist me.
0
 
LVL 1

Accepted Solution

by:
Thymos68 earned 500 total points
ID: 39924433
The Vlookup formula would be a simple way to populate that data.  If you're unfamiliar with Vlookup, one could describe it as a means to use to pull the desired data into a cell, by way of a lookup table.  

Vlookup will look down the left side of a table until it finds a cell that matches your reference cell, then deliver the result of a cell in column X (to it's right).

VLookup is written like this: =vlookup (A1,A1:C5,3,false)
    A1=lookup Cell
    A1:C5 = Lookup Table
    3 = Reult from column 3
    false = deliver only if exact match

For your file,

(with both files open) write this formula in the destination cell (K2 in this example):

VLOOKUP(B2,'[High-Schools-2014-with-PAAK-code.xlsx]Sheet1'!$A$1:$K$687,11,FALSE)

you then can copy that formula down through the sheet.  Any non-matches will result in #n/a.

The challenge I see however, is you need to have the school names match exactly.  An abbreviated, or alternative name will not result in a match.

Good luck
0
Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 

Author Comment

by:gsfc
ID: 39924480
Started off ok, but am receiving #N/A (which I expected) or #REF!  The paak code is found in the High-Schools-2014-with-PAAK-code.xlsx.  Why is it not returning the code?
0
 

Author Comment

by:gsfc
ID: 39924510
Oops, my fault.  Didn't use absolute cell reference in the formula.  This works like a charm!  Thank you so very much!
0
 

Author Closing Comment

by:gsfc
ID: 39924513
Wonderful idea, and will be extremely useful in the future.  Also, once I copied down the formula and had the codes in, I copied then pasted special to include just the values so I don't have to rely on the link to the other spreadsheet.  This works for what we needed to do.
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

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

: Microsoft Office Collaborate for free and online versions of Microsoft  Word, Excel, Powerpoint, OneNote, Onedrive , Email, Calendar etc. In short we can say that Microsoft office is a suite of servers, applications and services developed by  Micr…
How to get Spreadsheet Compare 2016 working with the 64 bit version of Office 2016
Viewers will learn a basic relationship technique in Power Pivot for Excel 2013.
Viewers will learn how to share Excel data with others from desktop Excel, as well as Excel Online via OneDrive, and embed an Excel file on a website.

623 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