?
Solved

Need to add information from one spreadsheet to another using a common key field

Posted on 2011-09-27
6
Medium Priority
?
216 Views
Last Modified: 2012-05-12
We have a MS spreadsheet table (Table 1) with 12 columns of information.  An important piece of information is located on another spreadsheet table (Table 2).  Both tables have a common field (Award Number).  The Award Amount information needs to be placed into Table 2.

I think that I should add a column to Table 1 with the same name as in table two.  I don't know how, but I believe that a command or procedure can be made to compare the two tables using the common field and then copy the Award Amount into Table 1 when a match of the Award number is found.  If necessary, Table 2 can be made to have only two columns (Award Number and Award Amount).

Any assistance that you can give will be appreciated.  
0
Comment
Question by:sherman6789
[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
  • 2
6 Comments
 
LVL 50

Expert Comment

by:barry houdini
ID: 36713800
If you can make Table 2 into two columns with Award Number in the first column and Award Amount in the second then you can use a regular VLOOKUP to pull that information into Table 1

Assume that a specific Award Number is in J2 in table1 then you can use a VLOOKUP like this in K2

=VLOOKUP(J2,Table2,2,0)

You'll get an #N/A error if the J2 Award Number isn't found in the first column

regards, barry
0
 

Author Comment

by:sherman6789
ID: 36713815
Thanks "barryhoudini", I'll try this tonight and respond tomorrow.
0
 
LVL 50

Accepted Solution

by:
barry houdini earned 2000 total points
ID: 36713850
OK, Note: it doesn't have to be two columns - that's just the simplest form.

As long as the Award Number column is to the left of the Award Amount column you can use VLOOKUP. The lookup value is looked up in the first column of the range you specify and a value is returned from the column indicated by the "column index" - that's the 2 in the above. so your table2 could be 5 columns wide from col F to col J, if Award Number is column F and Award Amount is in J then you would be returning a value from column 5 so the formula would be like this

=VLOOKUP(J2,Table2,5,0)

Excel's help on VLOOKUP is quite short but also reasonably helpful....

regards, barry
0
Get your Disaster Recovery as a Service basics

Disaster Recovery as a Service is one go-to solution that revolutionizes DR planning. Implementing DRaaS could be an efficient process, easily accessible to non-DR experts. Learn about monitoring, testing, executing failovers and failbacks to ensure a "healthy" DR environment.

 

Author Comment

by:sherman6789
ID: 36906656
Sorry for the delay.  I had to put this project on hold until Thur (Oct 6, 2011)  I will test and get back then.  Thanks for your assistance barryhoudini:.
0
 

Author Comment

by:sherman6789
ID: 36952122
The combining worked great.  Thanks.
0
 

Author Closing Comment

by:sherman6789
ID: 36952133
I really appreciated you assistance.  Thanks again.
0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

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

Some code to ensure data integrity when using macros within Excel. Also included code that helps secure your data within an Excel workbook.
Access developers frequently have requirements to interact with Excel (import from or output to) in their applications.  You might be able to accomplish this with the TransferSpreadsheet and OutputTo methods, but in this series of articles I will di…
The viewer will learn how to use a discrete random variable to simulate the return on an investment over a period of years, create a Monte Carlo simulation using the discrete random variable, and create a graph to represent the possible returns over…
Graphs within dashboards are meant to be dynamic, representing data from a period of time that will change each time the dashboard is updated with new data. Rather than update each graph to point to a different set within a static set of data, t…

777 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