+ Reply to Thread
Results 1 to 4 of 4

Collection data from source sheet

  1. #1
    Registered User
    Join Date
    10-01-2014
    Location
    Piatra Neamt
    MS-Off Ver
    365 small business
    Posts
    13

    Collection data from source sheet

    Hello,

    I need your help please in the fallowing problem:

    1. I have a table in Sheet-1 with a list of names but with no values in the corespondent 3 columns and they are repeatable on multiple rows.
    1. I have a data source in Sheet-2 with a list of unique names and corespondent values in 3 columns.
    3. Question: how can I collect the data from Sheet-2 (data base) to Sheet-1 (collection table) to corespondent names?

    To resume: If you find NAME from Sheet-1 in Sheet-2 source, then collect value from Sheet-2 to Sheet-1 on corespondent NAME and column.
    If you find ”ABRAHAM” in Sheet-2 data source, then copy ”ABRAHAM” C1, C2 and C3 data to ”ABRAHAM” corespondent C1, C2, and C3 in Sheet-1.
    Attached is the table with this names and data.

    Thank you.
    Vasile
    Attached Files Attached Files

  2. #2
    Valued Forum Contributor
    Join Date
    01-08-2011
    Location
    Portsmouth, England
    MS-Off Ver
    Excel 2007 to 2016
    Posts
    456

    Re: Collection data from source sheet

    VLOOKUP formulas will do this for you.

    On Sheet 1, in B2 put the following formula:

    =VLOOKUP([@NAME],Table134,2,FALSE)

    Then the same in C2 and D2, but change the number before ",FALSE" to 3 and 4 respectively.

    Because you have your sheet 1 as a table, the formulas should automatically copy down to all other rows.
    Excel is a constant learning process and it's great to help each other. If any of us have helped you today, a click on the "reputation" star on the left is appreciated.

  3. #3
    Registered User
    Join Date
    10-01-2014
    Location
    Piatra Neamt
    MS-Off Ver
    365 small business
    Posts
    13

    Re: Collection data from source sheet

    Thank you very much. It is working great in the TEST table.
    How can I adapt this formula to a bigger table? What is the general principle? My work has 300 rows with unique values in source table and 1900 rows in target table. Regarding columns I have from A to EM.

  4. #4
    Valued Forum Contributor
    Join Date
    01-08-2011
    Location
    Portsmouth, England
    MS-Off Ver
    Excel 2007 to 2016
    Posts
    456

    Re: Collection data from source sheet

    The principle is the same regardless of your table sizes.

    The VLOOKUP formula is constructed as...

    The field you want to find in your unique values. In this case this is [@NAME] which is the column in your target table (Table13)
    The range which holds your unique values. In this case this is your table on Sheet 2 (Table 134)
    The column number containing the value you want to appear in your target table, counting across from the left
    FALSE is used to ensure that there is an EXACT match to the NAME.

    So you need to find which columns have your source data and set the formula to find the NAME and count across to that column.

    Having your source and target values in tables makes this simpler as the rows will just expand as you add more records so you won't need to change the formula as more data is added.

    If a record in your target does not exist in your source table, you will see a #N/A value in your target table. If you want this to appear as something other than an error you can modify your formula to something like this:

    IFERROR(VLOOKUP([@NAME],Table134,2,FALSE),"Not Found")

    You can replace the "Not found" with any text or a number (leave out the quote marks if you want a number)

    Hope that helps, but ask more questions if you get stuck.

+ 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. Replies: 0
    Last Post: 02-29-2016, 02:44 AM
  2. Replies: 0
    Last Post: 07-21-2015, 10:26 PM
  3. copy data from one sheet to annother, format it; Update to refect changes on source sheet
    By simplificated in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 11-13-2013, 03:45 PM
  4. [SOLVED] MACRO: Send Data from 'Master Sheet' to 'Data Collection Sheet'
    By cjhiggins in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 08-15-2013, 09:45 PM
  5. [SOLVED] Paste data from source sheet to data sheet using 1st available row within a named range.
    By Krex14 in forum Excel Programming / VBA / Macros
    Replies: 18
    Last Post: 08-28-2012, 08:14 AM
  6. Separate sheet data collection
    By russkris in forum Excel General
    Replies: 14
    Last Post: 11-04-2009, 11:01 PM
  7. copying and pasting from source sheet to destination sheet without naming source sht?
    By Simon Lloyd in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 06-02-2006, 01:15 PM

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