HLOOKUP stands for horizontal lookup. The difference between HLOOKUP and VLOOKUP is that HLOOKUP searches for data in rows instead of columns.
Syntax
To start off, lets take a look at the HLOOKUP syntax.
=HLOOKUP(lookup_value,table_array,row_index_num,range_lookup)
lookup _value:
This is the value you want to match. The lookup _value can be a text, a logical value (TRUE or FALSE only), a number, or a cell that references a value.
table_array:
This is the range of data range that our function uses to perform our search. The array used in HLOOKUP must contain at least two rows. The first row of data contains the lookup_values.
* It is best to use an absolute cell reference for the table_array. By using “$” in the range, this keeps a cell reference fixed on a certain cell, or cells.
row_index_num:
Enter the row number of the table_array from which you want data returned from. For example:
- if the row_index_num is 1, it returns a value from the first row in the table_array;
- if the row_index_num is 2, it returns a value from the second row in the table_array.
range_lookup:
True or False. The range_lookup must be a logical value.
- If TRUE or if this argument is omitted, HLOOKUP will use an approximate match if it cannot find an exact match to the lookup_value. If an exact match is not found, HLOOKUP uses the next largest lookup_value.
- If FALSE, HLOOKUP will only use an exact match to the hookup_value. If there are two or more values in the first column of table_array that match the lookup_value, the first value found is used. If an exact match is not found, an #N/A error is returned.
HLOOKUP Example
In the image below, we are telling Excel in Cell B1 to look at the range B3:E4 and find to Ty Cobb. Once Ty Cobb is found, we want HLOOKUP to show Ty’s batting average.
This content is stolen from Excelbuddy.com If this is not removed immediately, charges will be pressed. A complaint is being filed and Google has been contacted.
ReplyDelete9/21/09