Vlookup Hlookup in Excel

Vlookup And Hlookup in Excel
Let’s see how we can use Hlookup and Vlookup in Excel in the same worksheet to extract information from our data. I’m doing this because many of my students wanted me to demonstrate the idea on the same worksheet.Our data is not sorted.
Let’s first use Hlookup to find out how many “Bolts” we sold in August. Then let us use Vlookup to find out again how many “Bolts” we sold in August. The result should of course be the same. There is no hard and fast rule when to use which function. It depends on how comfortable you are with the lookup functions. Many people prefer to use Vlookup. But as you saw you can also us Hlookup!
In Vlookup you define the first the item in column 1 and lookup the value in another column as shown in the example above. The data need not be sorted and for the [range_lookup] parameter you write “FALSE”. If you enter “TRUE” or omit the value for the [range_lookup], your data needs to be sorted in ‘ascending’ order or you might receive ‘strange’ results.
In Hlookup you define the item in the first row and lookup a value in the other rows in the same column. The topmost row has the row_index value of 1. Here gain you need to use [range_lookup] parameter as “False” if your data is not sorted which will be the case in most practical situations. In case you omit the parameter [range_lookup] or use “TRUE” you have to sort the data in ascending order to extract the correct information.
The table_array parameter is your complete data including the headers. To make things simpler and not to have to select all the necessary cells, it is better to select the range and assign it a name like mydata. So now instead of selecting the complete data every time you perform a Vlookup or Hlookup, you just write the name mydata.
The Excel training video demonstrates the whole idea.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.