View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
nakliwala nakliwala is offline
external usenet poster
 
Posts: 4
Default If statement with Vlookup - including ISNA function to compare two columns from different worksheets

On Sep 20, 8:10 pm, Pete_UK wrote:
You won't be able to use VLOOKUP in this situation. When using
VLOOKUP, it searches for a match in the first (left-most) column of
the table and then returns data from columns on the right of the first
column. You say that you would like to search Sheet2!ColumnB and then
return the matching data from column A. To do this you will have to
use an INDEX/MATCH combination, or move the columns in your data table
so that your current column A becomes column C or later.

Hope this helps.

Pete

On Sep 21, 12:58 am, nakliwala wrote:



hi,


I need some help creatng an 'IF' statement that contains a
'VLOOKUP' . In Sheet 1 i have an empty column called ROC (Column F)
that should contain the 'IF/VLOOKUP' function. This should look up
Column B in Sheet 2 and try to match them with entries in Sheet
1:Column D(but only the first four digits of the entries in Sheet
2:Column B. In Sheet 2:Column B row 58 the entry is 5730P; in Sheet 1
Column D, Row 18 the entry is 5730. The 'VLOOKUP' function needs to
identify that the first 4 digits are similar, then output the value of
Sheet 2 Column 'A' row 58 in the Column F Row 18.


if anyone has knowledge of if statement with vlookups please get back
to me.


Thank you,
Nakli


To get more of an idea on my question; My question is similar to the
thread below:- Hide quoted text -


- Show quoted text -


Hi Pete,
Thanks for your response,....

i used the following vlookup:

=IF(ISNA(VLOOKUP(D2,'Appendix 7'!$A$2:$B$103,2,FALSE))," ",
VLOOKUP(D2,'Appendix 7'!$A$2:$B$103,2,FALSE))

In the existing sheet the vlookup was in column F. And the value in
the "Appendix" tab column A was what needed to be matched. the
vlookup i used seemed to work fine...if u see any problems with it
please let me know.

Thanks for your help!

~Nakli