How to Create a Lookup Table in Excel & Google Sheets
This tutorial demonstrates how to create a lookup table in Excel and Google Sheets.
Table Source Data
Consider the following data in your worksheet.
The data is set up as a searchable database, with the data is stored in columns –called field names – and in rows – called records. Each row holds the data for an individual product. Setting out information in Excel in such a way enables you to sort and filter on the data, as well as use functions such as VLOOKUP. Your database can contain as many columns and rows available in a single Excel sheet (16,384 columns and 1,048,576 rows are available in each sheet but that might be a bit large for Excel to cope with!)
A lookup table enables you to fetch data from your existing table or range of data using the VLOOKUP Function.
- In cell G3, type in the name of the product to look up the qty in stock and price for.
- In cell H3, type in a VLOOKUP formula to get the qty in stock for that product. Type the formula:
- Repeat the process to look up the price of the product.
- When you type in a different product, the values in H3 and I3 change accordingly.
You can also create a drop-down list with data validation to choose a product from a list instead of typing in the product’s name.
- Click in the cell where you wish to insert the drop-down list, and then, in the Ribbon, go to Data > Data Tools > Data Validation > Data Validation.
- You can then choose List and select the range for the drop-down list. You can also customize the input message and error alert if you wish.
- Click OK to create the drop-down list.
- Choose a different product from the list to look up the qty and price from the original table data.
Lookup Table in Google Sheets
You can use the VLOOKUP Function to look up values in your table in Google Sheets as you do in Excel.