+ Reply to Thread
Results 1 to 6 of 6

VLOOKUP formula help to append multiple columns to data range

  1. #1
    Registered User
    Join Date
    12-13-2016
    Location
    Surrey
    MS-Off Ver
    2010
    Posts
    2

    VLOOKUP formula help to append multiple columns to data range

    I have two sheets in my excel. Sheet 1 Column1 contains the same data as Sheet2 Column2 "Identifier"

    When "Identifier" from sheet one matches that of sheet2 I want to capture columns 2,3,4,5 from sheet one in that row and append them to sheet2


    Help!

    Many thanks

  2. #2
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    25,475

    Re: VLOOKUP formula help to append multiple columns to data range

    Put this formula in C2 of Sheet2:

    =IFERROR(VLOOKUP($B2,Sheet1!$A:$E,COLUMNS($B:C),0),"")

    then you can copy this across and down as required.

    Hope this helps.

    Pete

  3. #3
    Registered User
    Join Date
    12-13-2016
    Location
    Surrey
    MS-Off Ver
    2010
    Posts
    2

    Re: VLOOKUP formula help to append multiple columns to data range

    Excel.JPG

    So I need to append columns B,C,D from sheet1 to sheet2 when PSA Identifier from sheet1 matches that in sheet2

  4. #4
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    25,475

    Re: VLOOKUP formula help to append multiple columns to data range

    It's not clear where you want them to go (i.e. in which columns), but the same basic formula that I gave you should accomplish that - you might need to change the $B2 to suit the row that you start on.

    Pete

  5. #5
    Registered User
    Join Date
    02-14-2015
    Location
    Sydney, Australia
    MS-Off Ver
    2010
    Posts
    6

    Re: VLOOKUP formula help to append multiple columns to data range

    Corrected response in subsequent version
    Last edited by mattgdunn; 12-13-2016 at 10:33 PM. Reason: I corrected my response in a subsequent version

  6. #6
    Registered User
    Join Date
    02-14-2015
    Location
    Sydney, Australia
    MS-Off Ver
    2010
    Posts
    6

    Re: VLOOKUP formula help to append multiple columns to data range

    Hi,

    VLOOKUP is what you need and a neat description follows on How to Use a VLOOKUP

    In your example you'll need a vlookup for each of the columns whose values you want to return (see "WhichColumn" below)

    A VLOOKUP looks for a value in the leftmost column of a table and then returns a value from the row that the searched for value is found (how far along that row is determined by you).

    The 4 parts to a VLOOKUP formula:

    SearchFor this is the value that is being searched for.

    WhereToSearch this is the range in which to search and in which the answer lives.

    WhichColumn this is the column in the WhereToSearch range which has the answer in it.

    NearOrExact you decide whether the VLOOKUP should search for a close value or an exact value.

    Structure of the VLOOKUP formula:

    =VLOOKUP ( SearchFor , WhereToSearch , WhichColumn , NearOrExact )

    ... so your formula might look a little like

    =VLOOKUP($B2,Sheet1!$A:$E,2, False ) & ", " & VLOOKUP($B2,Sheet1!$A:$E,3, False ) & ", " & VLOOKUP($B2,Sheet1!$A:$E,4, False ) & ", " & VLOOKUP($B2,Sheet1!$A:$E,5, False)

    Source: How to use a vlookup

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Append Data from a set range in sheet1 to next row in sheet 2
    By singerbatfink in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 01-03-2017, 05:51 AM
  2. Replies: 3
    Last Post: 10-08-2015, 04:15 PM
  3. [SOLVED] Need a VLookup formula for Multiple Columns
    By dyeager01 in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 12-04-2013, 01:07 PM
  4. append the corect data using vlookup or index
    By exceledge in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 06-20-2013, 06:51 PM
  5. Replies: 2
    Last Post: 03-05-2013, 03:07 PM
  6. Replies: 0
    Last Post: 07-27-2012, 10:15 AM
  7. multiple columns data append in single column
    By suresh3566 in forum Excel General
    Replies: 3
    Last Post: 06-11-2011, 07:52 AM

Tags for this Thread

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