close

I am trying vlookup and it is not quite working. I have 2 pages in the
worksheet, the first has 2 columns A and B. The second has the same
two columns A and B. I want the lookup to search for A1 on sheet 1,
find that cell on sheet 2 and return the value in column B, sheet 2.

I am using this formula:
=VLOOKUP(A2,Sheet2!A$2:A$955,1,0)

When the value returns it shows what is in column A on sheet 2 rather
than column B. If I change the 1 to a 2 it comes back with no value.

Thanks!--
patd7260
------------------------------------------------------------------------
patd7260's Profile: www.excelforum.com/member.php...oamp;userid=22625
View this thread: www.excelforum.com/showthread...hreadid=498743Your formula needs slight amendment, as follows:

=VLOOKUP(A1,Sheet2!A$2:B$955,2,0)

In your description you say you want to find a match with A1, though
your formula had A2. Also, the range needs to cover columns A and B,
and you want to return the value from column 2.

Hope this helps.

Pete=VLOOKUP(A2,Sheet2!A$2:B$955,2,0). You need the 2 in order to return data
from the 2nd column of the table. But you've got to define the table as
being two columns wide, hence the :B vs :A.quot;patd7260quot; wrote:

gt;
gt; I am trying vlookup and it is not quite working. I have 2 pages in the
gt; worksheet, the first has 2 columns A and B. The second has the same
gt; two columns A and B. I want the lookup to search for A1 on sheet 1,
gt; find that cell on sheet 2 and return the value in column B, sheet 2.
gt;
gt; I am using this formula:
gt; =VLOOKUP(A2,Sheet2!A$2:A$955,1,0)
gt;
gt; When the value returns it shows what is in column A on sheet 2 rather
gt; than column B. If I change the 1 to a 2 it comes back with no value.
gt;
gt; Thanks!
gt;
gt;
gt; --
gt; patd7260
gt; ------------------------------------------------------------------------
gt; patd7260's Profile: www.excelforum.com/member.php...oamp;userid=22625
gt; View this thread: www.excelforum.com/showthread...hreadid=498743
gt;
gt;

=VLOOKUP(A2,Sheet2!A$2:B$955,2,0)

You want the whole range (A:B) and you want to return the 2nd column in that
range.

You may want to read Debra Dalgleish's notes:
www.contextures.com/xlFunctions02.html

patd7260 wrote:
gt;
gt; I am trying vlookup and it is not quite working. I have 2 pages in the
gt; worksheet, the first has 2 columns A and B. The second has the same
gt; two columns A and B. I want the lookup to search for A1 on sheet 1,
gt; find that cell on sheet 2 and return the value in column B, sheet 2.
gt;
gt; I am using this formula:
gt; =VLOOKUP(A2,Sheet2!A$2:A$955,1,0)
gt;
gt; When the value returns it shows what is in column A on sheet 2 rather
gt; than column B. If I change the 1 to a 2 it comes back with no value.
gt;
gt; Thanks!
gt;
gt; --
gt; patd7260
gt; ------------------------------------------------------------------------
gt; patd7260's Profile: www.excelforum.com/member.php...oamp;userid=22625
gt; View this thread: www.excelforum.com/showthread...hreadid=498743

--

Dave Peterson

arrow
arrow
    全站熱搜
    創作者介紹
    創作者 software 的頭像
    software

    software

    software 發表在 痞客邦 留言(0) 人氣()