ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Vlookup return a ROW of data (https://www.excelbanter.com/excel-worksheet-functions/193019-vlookup-return-row-data.html)

thecdnmole

Vlookup return a ROW of data
 
Two sheets of data, same layout, different numbers, if I do a vlookup, how do
I get it to return the whole row of data, about a dozen columns? TIA!

Max

Vlookup return a ROW of data
 
Something like this, with the appropriate cell refs fixed, and using an
incrementer [ eg he COLUMNS($A:A) ] for the col index param for easy
propagation as you copy across:
=IF(ISNA(VLOOKUP($A1,Sheet1!$A:$Z,COLUMNS($A:A)+1, 0)),IF(ISNA(VLOOKUP($A1,Sheet2!$A:$Z,COLUMNS($A:A) +1,0)),"",VLOOKUP($A2,Sheet2!$A:$Z,COLUMNS($A:A)+1 ,0)),VLOOKUP($A1,Sheet1!$A:$Z,COLUMNS($A:A)+1,0))
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"thecdnmole" wrote:
Two sheets of data, same layout, different numbers, if I do a vlookup, how do
I get it to return the whole row of data, about a dozen columns? TIA!


Tieske[_2_]

Vlookup return a ROW of data
 
You might create a column on each sheet with all other data concatenated and
then compare those two columns

"thecdnmole" wrote in message
...
Two sheets of data, same layout, different numbers, if I do a vlookup, how
do
I get it to return the whole row of data, about a dozen columns? TIA!



Alan Beban[_2_]

Vlookup return a ROW of data
 
Tieske wrote:
You might create a column on each sheet with all other data concatenated
and then compare those two columns

"thecdnmole" wrote in message
...

Two sheets of data, same layout, different numbers, if I do a vlookup,
how do
I get it to return the whole row of data, about a dozen columns? TIA!



Here's one way:

=VLOOKUP(lookup_value,lookup_table,{2,3,4,5,6,7,8, 9,10,11,12})

array entered

Alan Beban


All times are GMT +1. The time now is 02:56 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com