The VLOOKUP function in Excel looks for a certain entry in the first column of a vertically oriented table. After it finds the row with the first match, it finds the column you specify in the function. The function then returns the cell contents of that row and column from the searched table. If you need to perform such a search through a separate spreadsheet in the same workbook, you can adapt the function to do so.
Select the cell in which you want the returned value. Click on the formula bar, the long empty box at the top of the screen.
Video of the Day
Type the following into the formula bar, taking care to include the quotation marks around the text you want to match: =VLOOKUP("put text here",
Click the tab of the other worksheet containing the searchable table, then highlight this table.
Click back to the original spreadsheet where you began typing the VLOOKUP function. Note that the table location has been inserted in the VLOOKUP function.
Click the formula bar again. Add a comma after the table location and type in which column you want the value returned from. For example, if you want to return two columns to the right of the search column, type "3."
Type a closing parenthesis and press "Enter."
If you will be creating several VLOOKUP functions across several cells, pointing to the same table in a different spreadsheet, type dollar signs into the table location of the formula you are copying. This way, the table won’t change when you copy the formula. For example, change =VLOOKUP(“dog breed”,Sheet2!A1:B30,2) into =VLOOKUP(“dog breed”, Sheet2!$A$1:$B$30,2).
Information in this article applies to Excel 2013 and Excel Online. Other versions or products may vary slightly or significantly.