#1   Report Post  
Kim17740
 
Posts: n/a
Default VLOOKUP

I have 2 spreadsheets of unequal rows (Spreadsheet 1 = 20,000 rows,
Spreadsheet 2 = 5,000 rows). Can I use IF, VLOOKUP, MATCH, or INDEX (or a
combination of the 4) to systematically go through each cell in the 1st
column of spreadsheet 1, find a match from the 1st column of spreadsheet 2,
then place a value that correlates with that match in the 2nd column of
spreadsheet 1. What would this formula look like? Any help would be
appreciated. Thanks.
  #2   Report Post  
Biff
 
Posts: n/a
Default

Hi!

When you say "2 spreadsheets", does that mean 2 workbooks
or 2 worksheets in the same workbook?

For 2 worksheets in the same workbook:

Assume Sheet1 A1:A20000
Sheet2 A1:B5000

In Sheet1 B1 enter this formula:

=IF(ISNA(VLOOKUP(A1,Sheet2!A$1:B$5000,2,0)),"",VLO OKUP
(A1,Sheet2!A$1:B$5000,2,0))

Copy down as needed.

This will lookup the value from Sheet1 A1 in Sheet2
A1:A5000 and if a match is found will return the
corresponding value from Sheet2 B1:B5000. If no match is
found the formula will return "" which leaves the cell
blank. (not to be confused with EMPTY)

For 2 WORKBOOKS:

Basically it's the same except you need to include the
workbook (file) name:

=IF(ISNA(VLOOKUP(A1,[Book2]
Sheet1A$1:B$5000,2,0)),"",VLOOKUP(A1,[Book2]Sheet1!
A$1:B$5000,2,0))

Biff

-----Original Message-----
I have 2 spreadsheets of unequal rows (Spreadsheet 1 =

20,000 rows,
Spreadsheet 2 = 5,000 rows). Can I use IF, VLOOKUP,

MATCH, or INDEX (or a
combination of the 4) to systematically go through each

cell in the 1st
column of spreadsheet 1, find a match from the 1st column

of spreadsheet 2,
then place a value that correlates with that match in the

2nd column of
spreadsheet 1. What would this formula look like? Any

help would be
appreciated. Thanks.
.

  #3   Report Post  
Kim17740
 
Posts: n/a
Default

That formula worked perfectly! Thank you! Thank you! Thank you!

"Biff" wrote:

Hi!

When you say "2 spreadsheets", does that mean 2 workbooks
or 2 worksheets in the same workbook?

For 2 worksheets in the same workbook:

Assume Sheet1 A1:A20000
Sheet2 A1:B5000

In Sheet1 B1 enter this formula:

=IF(ISNA(VLOOKUP(A1,Sheet2!A$1:B$5000,2,0)),"",VLO OKUP
(A1,Sheet2!A$1:B$5000,2,0))

Copy down as needed.

This will lookup the value from Sheet1 A1 in Sheet2
A1:A5000 and if a match is found will return the
corresponding value from Sheet2 B1:B5000. If no match is
found the formula will return "" which leaves the cell
blank. (not to be confused with EMPTY)

For 2 WORKBOOKS:

Basically it's the same except you need to include the
workbook (file) name:

=IF(ISNA(VLOOKUP(A1,[Book2]
Sheet1A$1:B$5000,2,0)),"",VLOOKUP(A1,[Book2]Sheet1!
A$1:B$5000,2,0))

Biff

-----Original Message-----
I have 2 spreadsheets of unequal rows (Spreadsheet 1 =

20,000 rows,
Spreadsheet 2 = 5,000 rows). Can I use IF, VLOOKUP,

MATCH, or INDEX (or a
combination of the 4) to systematically go through each

cell in the 1st
column of spreadsheet 1, find a match from the 1st column

of spreadsheet 2,
then place a value that correlates with that match in the

2nd column of
spreadsheet 1. What would this formula look like? Any

help would be
appreciated. Thanks.
.


  #4   Report Post  
Biff
 
Posts: n/a
Default

You're welcome! Thanks for the feedback.

Biff

-----Original Message-----
That formula worked perfectly! Thank you! Thank you!

Thank you!

"Biff" wrote:

Hi!

When you say "2 spreadsheets", does that mean 2

workbooks
or 2 worksheets in the same workbook?

For 2 worksheets in the same workbook:

Assume Sheet1 A1:A20000
Sheet2 A1:B5000

In Sheet1 B1 enter this formula:

=IF(ISNA(VLOOKUP(A1,Sheet2!A$1:B$5000,2,0)),"",VLO OKUP
(A1,Sheet2!A$1:B$5000,2,0))

Copy down as needed.

This will lookup the value from Sheet1 A1 in Sheet2
A1:A5000 and if a match is found will return the
corresponding value from Sheet2 B1:B5000. If no match

is
found the formula will return "" which leaves the cell
blank. (not to be confused with EMPTY)

For 2 WORKBOOKS:

Basically it's the same except you need to include the
workbook (file) name:

=IF(ISNA(VLOOKUP(A1,[Book2]
Sheet1A$1:B$5000,2,0)),"",VLOOKUP(A1,[Book2]Sheet1!
A$1:B$5000,2,0))

Biff

-----Original Message-----
I have 2 spreadsheets of unequal rows (Spreadsheet 1 =

20,000 rows,
Spreadsheet 2 = 5,000 rows). Can I use IF, VLOOKUP,

MATCH, or INDEX (or a
combination of the 4) to systematically go through

each
cell in the 1st
column of spreadsheet 1, find a match from the 1st

column
of spreadsheet 2,
then place a value that correlates with that match in

the
2nd column of
spreadsheet 1. What would this formula look like? Any

help would be
appreciated. Thanks.
.


.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
make a vlookup using a variable path Alex St-Pierre Excel Worksheet Functions 1 March 2nd 05 11:54 PM
Table Array in VLOOKUP Relies on Data Validation willydlish Excel Worksheet Functions 2 February 16th 05 03:20 AM
vlookup data hidden within worksheet Excel Worksheet Functions 0 January 26th 05 12:09 PM
Vlookup info being used without vlookup table attached? Excel Worksheet Functions 0 January 25th 05 10:43 AM
VLOOKUP not working Scott Excel Worksheet Functions 3 November 12th 04 08:06 PM


All times are GMT +1. The time now is 09:17 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"