Вы находитесь на странице: 1из 7

8/25/2017 How can I pull data from one Excel sheet to another automatically?

I want to run a comparison on products I've sold one quarter versus another.

Excel Tricks Microsoft Excel

There's more on Quora...


How can I pull data from one Excel sheet to another
Pick new people and topics to follow and see the
automatically? I want to run a comparison on best answers on Quora.
products I've sold one quarter versus another. Is
Update Your Interests
there a way I can pull in the sales quantity from the
other sheet and add it to the row to compare?
This question previously had question details. You can find them in the question
comments.

Answer Request Follow 39 Comment 1 Share Downvote

Promoted by Fieldbook

As simple as a spreadsheet, as powerful as a database.


If you're frustrated with tracking projects, sales or inventory in a spreadsheet, try
Fieldbook instead.

Sign up at fieldbook.com

10 Answers

Peter Recson, In Excel for 60%+ of my day


Updated May 29, 2015

Index-match function!

More Related Questions

In other languages

En espaol: Cmo puedo extraer datos de una hoja


de Excel a otra automticamente?

Question Stats

38 Public Followers

412,221 Views
Last Asked Jan 28, 2016
Edits

In the above example, blue text represents numbers you've inputted and black text
represents anything that is a calculation or excel function.

Pretending that rows 2 - 10 represent your excel spreadsheet from Q1 and lines 12 - 22
represent your other spreadsheet from Q2, just type in the formula as shown above,
locking the necessary cells (e.g. D$4 "locks" row 4) and copy the formula down or
across.

A couple of things to keep in mind when using index-match:


You need to make sure the names of the products are exactly the same.
That means no extra spaces or hyphens, etc. If there are additional
characters, you might need to use text editing functions to remove them (e.g.
take out spaces using the Trim() function), otherwise you could end up with

https://www.quora.com/How-can-I-pull-data-from-one-Excel-sheet-to-another-automatically-I-want-to-run-a-comparison-on-products-Ive-sold-one-quart 1/7
8/25/2017 How can I pull data from one Excel sheet to another automatically? I want to run a comparison on products I've sold one quarter versus another.
an #N/A error message. It would probably be better to match up by a product
ID rather than product name.

Products that existed in Q1 but not Q2, and vice versa. Another nice thing
about index-match is that it will call out any anomalies: In the above, Candy
Canes is an item that you only introduced in Q2. Index-match calls this out:
there is no quarter-over-quarter comp for candy canes. You may also have
sold products in Q1 that you no longer oered in Q2; you can run an index-
match against the Q2's inputted data to quickly check.

Final checks. Referring to the above example, you should check to make
sure you've captured everything from Q1 with the index-match in "Quarter 2
Spreadsheet", by summing the quantity numbers pulled in to ensure it
matches the total in "Quarter 1 Spreadsheet". If the sums don't match up,
you're missing something -- check for any #N/A errors or if your forgot to
include a product name in the "Quarter 2 Spreadsheet."

Edit: Per Chai Yong 's comment, a Vlookup (or Hlookup, depending on how your data is
presented) would work just as well. I, personally decided to provide my answer around
index-match because I prefer it over v- and hlookup, and for the other reasons noted in
the comments below.
309.5k Views 9 Upvotes

Upvote 9 Downvote

Add a comment... Recommended All

Promoted by Poll Everywhere


Deliver an unforgettable presentation! Try for free.
Turn passive listeners into active participants with an interactive presentation.

Sign up at polleverywhere.com

Related Questions More Answers Below

Is there a way to automatically extract a row of data in one sheet to another in Excel?

How can I pull specific data from one Excel sheet and import it into the correct fields on
another sheet?

How do I duplicate data from one Excel sheet to another? I need to add rows depending
on the amount of data entered in the first sheet.

How can you pull data from one sheet to another in Excel based on a particular value?

How can I automatically duplicate data from one Excel sheet to another?

Paramdeep Singh, Power Excel User and Trainer @


www.edupristine.com/ca.
Answered May 3, 2013
There are two ways to do this. Use VLookup or Use Combination of Index-Match.

Lets say you have your data in two sheets, X and Y

https://www.quora.com/How-can-I-pull-data-from-one-Excel-sheet-to-another-automatically-I-want-to-run-a-comparison-on-products-Ive-sold-one-quart 2/7
8/25/2017 How can I pull data from one Excel sheet to another automatically? I want to run a comparison on products I've sold one quarter versus another.

Please note that the same products might not be selling in all the quarters

Now, when I want to consolidate in a separate sheet, I would rst of all put all product
categories in that sheet.

Post that, I can use Vlookup to nd the value. The only problem is that if the value
does not exist, I would get a #N/A error. To avoid that you can use iferror to make the
value 0, if it is not found. Please note that the array where you are looking for the key,
has to be protected with $s

Similarly I can use a combination of Index and Match, protect the key column with $
and ensure that I can avoid #N/A errors with iferror

168.6k Views 13 Upvotes

Upvote 13 Downvote

Add a comment... Recommended All

Scott Gartner, Using Excel for longer than I want to remember, and thanks
for bringing it up!
Answered May 25, 2015

I agree with others that VLOOKUP is the way you want to nd the relationships
between the source data (a list of things) and the target cell (which points to one of the
items in the list). But so far I don't see that anyone has explained how to use
VLOOKUP to look into another spreadsheet, so I'll focus on that aspect.

It is much easier in general to have the list of things on one tab in the same workbook
https://www.quora.com/How-can-I-pull-data-from-one-Excel-sheet-to-another-automatically-I-want-to-run-a-comparison-on-products-Ive-sold-one-quart 3/7
8/25/2017 How can I pull data from one Excel sheet to another automatically? I want to run a comparison on products I've sold one quarter versus another.
as the target cells, but it is not required. The basic formula for Excel cross-references
is:

[workbookPath]tabName!cellAddress

So, to address a cell in column A and row 23 on the rst sheet (if you haven't renamed
it, it will be called "Sheet1") in a workbook called test.xlsx you would type:

=[test.xlsx]Sheet1!A23

Note that if any of these have spaces in them you should wrap them in quotes, like
this:

='[test.xlsx]Some Fantastic Sheet Name'!A23


='[c:\My Documents\test.xlsx]Sheet1'!A23

There are also other complications like relative addressing versus xed addressing
that you may already understand, so I won't explain them, but if you Google those
terms you'll get an eyeful.

More info: Create an external reference (link) to a cell range in another workbook

206.1k Views 4 Upvotes

Upvote 4 Downvote

Add a comment... Recommended All

Andrew Lister, User of Excel since 1988 (more or less), on both Mac and PC, Related Questions
with VBA experience
Answered May 14, 2015 Is there a way to automatically extract a row of data in
I think you should invest some time in learning how to use pivot tables and charts. one sheet to another in Excel?

You build a single table with all your data and then sort, tabulate and lter to your How can I pull specific data from one Excel sheet and
heart's content, in seconds. It really is one of the absolutely best features of Excel. import it into the correct fields on another sheet?

73.3k Views 10 Upvotes How do I duplicate data from one Excel sheet to
another? I need to add rows depending on the amount
Upvote 10 Downvote of data entered in the first sheet.

How can you pull data from one sheet to another in


Add a comment... Recommended All
Excel based on a particular value?

How can I automatically duplicate data from one Excel


sheet to another?
Saswat Kumar Swain, worked at Microsoft Excel
Answered Feb 15, 2016 What is the formula for automatically fetching live data
from one excel sheet to another sheet?
It's "VLOOKUP" .Basically, 'VLOOKUP' lets you search for specic information in
your spreadsheet. How can I duplicate filtered data from one sheet to
another sheet automatically?
When you need to nd and extract a column of data from one table and place it in
How does auto populating the data from one Excel
another, use the "VLOOKUP" function. This function allows you to nd data in one sheet to another sheet work?
table using some identier it has in common with another table. The two tables can
be on dierent sheets or even on dierent workbooks.

There is also an "HLOOKUP" function, which does the same thing, but with data
arranged horizontally, across rows.

56k Views 7 Upvotes

Upvote 7 Downvote

Add a comment... Recommended All

1
Read Answer Notifications Search Quora Ask Question

https://www.quora.com/How-can-I-pull-data-from-one-Excel-sheet-to-another-automatically-I-want-to-run-a-comparison-on-products-Ive-sold-one-quart 4/7
8/25/2017 How can I pull data from one Excel sheet to another automatically? I want to run a comparison on products I've sold one quarter versus another.
Anshul Rathi, works at HCL Infosystems
Answered Jun 2, 2015

Use VLOOKUP.

Its one of the most powerful and useful formula in excel. It will match index and fetch
the data you want.

Refer to this url for tutorial VLOOKUP: What it is, and when to use it

65.2k Views

Upvote Downvote

Add a comment... Recommended All

Mehul Singh, Data hustler, powerpoint pimp


Answered May 2, 2013

What you are looking for a reference lookup functions. You can use vlookup, index-
match or a simple "= target Cell reference". For 2000 rows you may have to use a
formula.

76.4k Views 1 Upvote

Upvote 1 Downvote

Add a comment... Recommended All

Ted Pettit, former A/C Repair and Screen Door Sales


Answered Jul 28, 2015

This practically screams out "Pivot Table Report!" Actually, there is no need to
separate your entries for each quarter onto dierent worksheets unless you want to.
You can put every entry into one table and then generate a Pivot Table from that. The
pivot can be designed to show the order quantities for each quarter all from one single
master table.
My example:
This is the order entry table. It shows all of the pertinent data for each order:


I used helper tables along with vlookup and data validation to keep everything
associated properly and to ease data entry:

https://www.quora.com/How-can-I-pull-data-from-one-Excel-sheet-to-another-automatically-I-want-to-run-a-comparison-on-products-Ive-sold-one-quart 5/7
8/25/2017 How can I pull data from one Excel sheet to another automatically? I want to run a comparison on products I've sold one quarter versus another.

I created a pivot table to summarize (aggregate) the data to show what I wanted:

This is much quicker and ecient than the way you were describing and it is
somewhat akin to how a relational database works.
Any time you want to quickly summarize data, the Pivot Table should be the rst
thing you pull out of your Excel toolbox. If you nd you cannot summarize the data
to the point you need using pivots, you can still copy the data out of the pivot table
and paste it into normal cells and go from there.
This is a very simple example. May I suggest you do an internet search for pivot table
how to's?
This site has a nice Pivot Table course but there are many others:
Master Excel Pivot Table in 23 Steps & Be a Pivot Table Wizard!

112.4k Views 4 Upvotes

Upvote 4 Downvote

Add a comment... Recommended All

Joel Chan, Use it everyday


Answered May 1, 2013

The vlookup function is your friend: VLOOKUP - Excel - Oce.com

93.4k Views 3 Upvotes

Upvote 3 Downvote

Add a comment... Recommended All

Related Questions

https://www.quora.com/How-can-I-pull-data-from-one-Excel-sheet-to-another-automatically-I-want-to-run-a-comparison-on-products-Ive-sold-one-quart 6/7
8/25/2017 How can I pull data from one Excel sheet to another automatically? I want to run a comparison on products I've sold one quarter versus another.
What is the formula for automatically fetching live data from one excel sheet to another
sheet?

How can I duplicate filtered data from one sheet to another sheet automatically?

How does auto populating the data from one Excel sheet to another sheet work?

How can I populating a new row from one sheet to another sheet in same workbook in
Excel 2010?

How can I pull specific data from various Excel workbooks and import it into the correct
fields on another sheet?

How can I program Excel to automatically duplicate information from one sheet to
another?

Is there a way to use VLOOKUP (Excel) for data from another sheet when there are
duplicate names on one sheet?

How do I compare two values, one input and another from a excel sheet?

Can I pull the name of a product from one sheet of Excel to the other sheet of the same
Excel using any formula in Excel?

In excel how do I extract data from a list on one sheet to format and populate another
sheet?

Top Stories from Your Feed

https://www.quora.com/How-can-I-pull-data-from-one-Excel-sheet-to-another-automatically-I-want-to-run-a-comparison-on-products-Ive-sold-one-quart 7/7

Вам также может понравиться