+ Reply to Thread
Results 1 to 5 of 5

Pasting in cells from a .csv exported report. VLOOKUP is not populating on sheet.

  1. #1
    Registered User
    Join Date
    07-17-2012
    Location
    Minneapolis
    MS-Off Ver
    Excel 2003
    Posts
    6

    Question Pasting in cells from a .csv exported report. VLOOKUP is not populating on sheet.

    I have a workbook I am putting together for a customer. I have a formula in column E on sheet one that should be populating based data pasted into sheet 2. That formula is:

    =IF(ISNA(VLOOKUP(Sheet1!B2,Sheet2!$A$2:$B$600,3,)FALSE),"",VLOOKUP(Sheet1!B2,Sheet2!$A$2:$B$600,3,)FALSE))

    I am pasting in data from the .csv export into columns A and B on sheet 2. The expectation is that the values from column B on sheet 2 will appear in column E on sheet 1. This works if I manually place test data in sheet 2 or if I copy/paste values from another spreadsheet. What could be causing this to not populate. I get no errors, just a blank column E.

    Column A sheet 2 and Column B sheet 1 are both number formatted, custom, with a format of 00000-0000-00.

    Thanks.

  2. #2
    Forum Contributor BenMiller's Avatar
    Join Date
    12-06-2011
    Location
    New Jersey
    MS-Off Ver
    Excel 2010
    Posts
    254

    Re: Pasting in cells from a .csv exported report. VLOOKUP is not populating on sheet.

    First of all: Your VLOOKUP should be structured as follows:

    =VLOOKUP(Sheet1!B2,Sheet2!$A$2:$B$600,3,FALSE) not sure where you got the extra parentheses from.

    Also, you can't pull the third column =VLOOKUP(Sheet1!B2,Sheet2!$A$2:$B$600,3,FALSE) out of $A$2:$B$600 - there are only two columns in that. It should give you a #REF error.

    So assuming you want values from column B on Sheet2, your final formula should be

    =IF(ISNA(VLOOKUP(B2,Sheet2!$A$2:$B$600,2,FALSE)),"",VLOOKUP(B2,Sheet2!$A$2:$B$600,2,FALSE))

  3. #3
    Forum Expert Tinbendr's Avatar
    Join Date
    06-26-2012
    Location
    USA
    MS-Off Ver
    Office 2010
    Posts
    2,125

    Re: Pasting in cells from a .csv exported report. VLOOKUP is not populating on sheet.

    Ben beat me to it..
    David
    (*) Reputation points appreciated.

  4. #4
    Registered User
    Join Date
    07-17-2012
    Location
    Minneapolis
    MS-Off Ver
    Excel 2003
    Posts
    6

    Re: Pasting in cells from a .csv exported report. VLOOKUP is not populating on sheet.

    Thanks for the replies.

    The 3 in my VLOOKUP was just a typo. It was correct on the actual worksheet.

    I copies in what BenMiller provided and it still did not populate any values. However, if I manually enter values in column B, sheet 2 that match values in column A, sheet 1, it works. Also, if I copy values from another workbook it also works fine. However, if I paste in values from the .csv, it still just leaves my column E blank.

    There must be something in the data that I am pasting in that is causing an issue.

  5. #5
    Forum Contributor BenMiller's Avatar
    Join Date
    12-06-2011
    Location
    New Jersey
    MS-Off Ver
    Excel 2010
    Posts
    254

    Re: Pasting in cells from a .csv exported report. VLOOKUP is not populating on sheet.

    What happens if you run the VLOOKUP by itself, without the IF(ISNA( around it?

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1