Chhaya Wagmi

# Working with Lookup Functions in Excel

### Chhaya Wagmi

• Sep 14, 2020
• 12 Min read
• 24,149 Views
• Sep 14, 2020
• 12 Min read
• 24,149 Views
Business Professional
Microsoft Excel

## Introduction

In this guide, you will learn how to work with lookup functions in Microsoft Excel 2019. This guide will help you to perform tasks like working with arrays of data, providing information about a range, returning the location of a given address or value, or looking up specific values.

There are a number of various lookup functions in Excel 2019:

• ADDRESS Function
• AREAS Function
• UNIQUE Function
• CHOOSE Function
• COLUMN Function
• COLUMNS Function
• INDEX Function
• MATCH Function
• VLOOKUP Function
• HLOOKUP Function
• LOOKUP Function

## ADDRESS Function

The `ADDRESS` function returns "the address for a cell based on the given row and column numbers," according to Excel's documentation.

The most commonly used syntax for the `ADDRESS` function contains the row and column number:

``1=ADDRESS(row_number, column_number)``

Consider a scenario in which you can implement the `ADDRESS` function:

ABCDEFGH
Sr. No.Row_NumColumn_NumAbs_NumA1Sheet_textAddress FormulaResult
114=ADDRESS(B1, C1)?
2351=ADDRESS(B2,C2,D2)?
32121=ADDRESS(B3, C3, D3, E3)?
471130sheet1=ADDRESS(B4, C4, D4, E4, F4)?
5181241=ADDRESS(B5, C5, D5, E5)?

After applying the formula, the result will be updated as shown below:

ABCDEFGH
Sr. No.Row_NumColumn_NumAbs_NumA1Sheet_textAddress FormulaResult
114=ADDRESS(B1, C1)\$D\$1
2351=ADDRESS(B2,C2,D2)\$E\$3
32121=ADDRESS(B3, C3, D3, E3)A\$2
471130sheet1=ADDRESS(B4, C4, D4, E4, F4)sheet1!R7C11
5181241=ADDRESS(B5, C5, D5, E5)L18

## AREAS Function

The `AREAS` function returns "the number of areas in a given reference where an area is a range of contiguous cells or a single cell," according to Excel's documentation.

It has the following syntax:

``1=AREAS(reference_to_cell(s)_areas)``

Consider this data in which you can implement the `AREAS` function:

ABCDEFGH
Sr. No.Row_NumColumn_NumAbs_NumA1Sheet_textAREA FormulaResult
114=AREAS(B1:C1)?
2351=AREAS(B2:C2, D2)?
32121=AREAS(B3:E3)?
471130sheet1=AREAS(B4:D4, E4, F4)?
5181241=AREAS(B5:C5 B5)?

After applying the formula, the result will be updated as shown below:

ABCDEFGH
Sr. No.Row_NumColumn_NumAbs_NumA1Sheet_textAREA FormulaResult
114=AREAS(B1:C1)1
2351=AREAS(B2:C2, D2)2
32121=AREAS(B3:E3)1
471130sheet1=AREAS(B4:D4, E4, F4)3
5181241=AREAS(B5:C5 B5)1

## UNIQUE Function

The `UNIQUE` function "returns a list of unique values in a list or range," according to Excel's documentation.

It has the following syntax:

``1=UNIQUE(range_of_cells)``

Consider the table below in which you have a few values in different rows:

ABC
SR. NO.VALUEUNIQUE VALUES
115
218
315
416
518

You can apply the `=UNIQUE(B1:B5)` function to get the unique values from the given list of values. The output will be as shown below:

ABC
SR. NO.VALUEUNIQUE VALUES
11515
21816
31518
416
518

## CHOOSE Function

The `CHOOSE` function starts with an integer argument which acts as a selection index for the subsequent arguments.

It has the following syntax:

``1=CHOOSE(selection_index, arg1, arg2, arg3, ...)``

Consider the following table:

ABC
SR. NO.FunctionOutput
1=CHOOSE(4,"Monday", "Tuesday", "Wednesday", "Thursday", "Friday")?
2=CHOOSE(2, 2, "Cat", 23, 321, "ABC")?
3=CHOOSE(1,34,323,3221,1221)?

In each row, after applying the function, the result will be updated as shown below:

ABC
SR. NO.FunctionOutput
1=CHOOSE(4,"Monday", "Tuesday", "Wednesday", "Thursday", "Friday")Thursday
2=CHOOSE(2, 2, "Cat", 23, 321, "ABC")Cat
3=CHOOSE(1,34,323,3221,1221)34

## COLUMN and COLUMNS Function

The `COLUMN` function "returns the column number of the given cell reference," whereas the `COLUMNS` function "returns the number of columns in the given array or reference," according to Excel's documentation.

Here's the syntax:

``````1=COLUMN([address])
2=COLUMNS([range])``````

Here's an example to understand their implementation. The function `=COLUMN(B10)` returns 2 as output because column B is the second column, whereas`=COLUMNS(A1:E1)` returns `5` as the output because the array is spread in five columns.

## INDEX Function

The `INDEX` function "returns a value or the reference to a value from within a table or range," according to Excel's documentation.

It has the following syntax:

``1=INDEX(range, row_number, optional_column_number) ``

Consider the example below.

ABCDEFG
SR. NO.NAMESUBJECTGRADERANKFORMULAOUTPUT
1ALISHAMATHA2=INDEX(B1:D1, 1, 3)?
2BENSCIENCEA1=INDEX(B1:D5, 2, 1)?
3CATHYPHYSICSD3=INDEX(B1:E5, 3, 2)?
4DRAKECHEMISTRYC4=INDEX(B1:E5, 2, 4)?
5ELEECONOMYB5=INDEX(B1:E5, 5, 4)?

After applying the formula, the result will be updated as shown below:

ABCDEFG
SR. NO.NAMESUBJECTGRADERANKFORMULAOUTPUT
1ALISHAMATHA2=INDEX(B1:D1, 1, 3)A
2BENSCIENCEA1=INDEX(B1:D5, 2, 1)BEN
3CATHYPHYSICSD3=INDEX(B1:E5, 3, 2)PHYSICS
4DRAKECHEMISTRYC4=INDEX(B1:E5, 2, 4)1
5ELEECONOMYB5=INDEX(B1:E5, 5, 4)5

## MATCH Function

The `MATCH` function "searches a specific item in a range of cells, and returns the relative position of that item in the given range," according to Excel's documentation.

It has the following syntax:

``1=MATCH(input, range)``

Consider the example below.

ABCDEF
SR. NO.NAMEMARKSGRADEFUNCTIONOUTPUT
1ALISHA35F=MATCH("BEN", B1:B5, 0)?
2CATHY75D=MATCH(94, C1:C5, 1)?
3BEN78C=MATCH("F", D1:D5, -1 )?
4ELE94B=MATCH("A", D1:D5, -1 )?
5DRAKE95A=MATCH("ELE", B1:B5, 0)?

After applying the function, the result will be updated as shown below:

ABCDEF
SR. NO.NAMEMARKSGRADEFUNCTIONOUTPUT
1ALISHA35F=MATCH("BEN", B1:B5, 0)3
2CATHY75D=MATCH(94, C1:C5, 1)4
3BEN78C=MATCH("F", D1:D5, -1 )1
4ELE94B=MATCH("A", D1:D5, -1 )5
5DRAKE95A=MATCH("ELE", B1:B5, 0)4

## VLOOKUP Function

You can use the `VLOOKUP` function "when you need to find values in a table or a range by row," according to Excel's documentation. The `VLOOKUP` function has the following syntax:

``1=VLOOKUP(input, range, selection_index_from_column)``

Consider a scenario where you can implement the `VLOOKUP` function. Say you have a database that contains information for all teachers in a class, as below:

If you want to know the `D.O.B.` for `ID = 116`, you would write the `=vlookup(116,A2:E11,5,0)` function and get the output `12-Aug-92`, as shown below:

## HLOOKUP Function

The `HLOOKUP` function works in a similar manner as the `VLOOKUP` function. It’s short for `Horizontal LOOKUP`, and "it searches for a value in the top row of a given table or an array of values, then returns a value in the same column from a row you specify in the table or array," according to Excel's documentation. The `HLOOKUP` function has the following syntax:

``1=HLOOKUP(input, range, selection_index_by_row)``

Consider once again the teachers' database :

To find the `D.O.B.` for `ID = 115`, you would write the `=HLOOKUP(115,B1:K5,5,0)` function and get the output `03-Aug-88`, as shown below:

## LOOKUP Function

The `LOOKUP` function can be used "when you need to look in a single row or column and find a value in the same position in a second row or column," according to Excel's documentation.

The `LOOKUP` function has the following syntax:

``1=LOOKUP(input, range)``

Consider the example below.

ABCDEFG
SR. NO.IDNAMELAST NAMEDEPARTMENTFormulaOutput
2101AlexaDasCSE=LOOKUP(103,B2:B6,E2:E6)?
3102AlishaLoredoEEE=LOOKUP(107,B2:B6,E2:E6)?
4103DevRaghuECE=LOOKUP(B3,B2:B6,C2:C6)?
5104DougVermaIT=LOOKUP("alisha",C2:C6,D2:D6)?
6105JameWillEEE=LOOKUP(105,B2:B6,D2:D6)?

After applying the `LOOKUP` function, the result will be updated as shown below:

ABCDEFG
SR. NO.IDNAMELAST NAMEDEPARTMENTFormulaOutput
2101AlexaDasCSE=LOOKUP(103,B2:B6,E2:E6)ECE
3102AlishaLoredoEEE=LOOKUP(107,B2:B6,E2:E6)EEE
4103DevRaghuECE=LOOKUP(B3,B2:B6,C2:C6)Alisha
5104DougVermaIT=LOOKUP("alisha",C2:C6,D2:D6)Loredo
6105JameWillEEE=LOOKUP(105,B2:B6,D2:D6)Will

## Conclusion

In this guide, you've learned various LOOKUP functions in MS Excel 2019. They can be used to automatically perform many operations and tasks that are otherwise time-consuming and prone to mistakes, such as working with arrays of data. Now you can explore by using these Excel features in your daily work.