ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   please give me an example of vlookup (https://www.excelbanter.com/excel-worksheet-functions/28063-please-give-me-example-vlookup.html)

Garth

please give me an example of vlookup
 

--
gsimpson

Adam Molinaro

You have 2 lists, and you want to see if records of one list are contained in
another.

First List =
Animal Quantity
dog 3
rabbit 6
snake 5
eagle 5
pig 3
horse 5
hamster 7
hamster 7
gopher 6
goat 4

Second List =
SUBLIST VLOOKUP
RABBIT rabbit
snake snake
dragon #N/A

In your VLOOKUP column, type the formula =VLOOKUP(D3,$A$2:$B$11,1,FALSE),
assuming the first table was in columns A and B, and the second table is in
column D ('RABBIT' is in D3). With the formula, you are effectively saying,
"look at D3, then go to table $A$2:$B$11, look at the leftmost column, and
see if you find a match. If you do, return the value in the 1st column ('1'
in the formula)." The 'FALSE' indicates you want to find an exact match. If
this is omitted, or you put 'TRUE,' it will look for approximate matches,
which will [probably] be of no use whatsoever. In the example, you can see
'dragon' got an '#N/A' because it does not exist in the first table.
Furthermore, You can return other values besides the first column; if you
type in a '2' instead of a '1' in the formula, for the RABBIT record, you
would show '6.'

I hope that helps.

Adam.





"Garth" wrote:


--
gsimpson


Neil

For a simple tutorial on using Vlookup, check out the Excel pages at my
website.

www.nwarwick.co.uk

HTH

Nei

"Garth" wrote:


--
gsimpson


Don Guillett

Have you tried HELP index looking for VLOOKUP?

--
Don Guillett
SalesAid Software

"Garth" wrote in message
...

--
gsimpson





All times are GMT +1. The time now is 07:44 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com