+ Reply to Thread
Results 1 to 2 of 2

Lookup several elements from a table updated each month

  1. #1
    Registered User
    Join Date
    11-27-2019
    Location
    Berlin, Germany
    MS-Off Ver
    Excel 16.31
    Posts
    1

    Lookup several elements from a table updated each month

    Hello to the community,

    I've been browsing here now and then but this is the first time I'm posting :-)
    So here is my issue, I have been wondering for a long time if there was a smart and easy way to do that - maybe one of you can help me ?

    Let's say I have a table of raw data with about 10 lines and 10 columns.
    This table is updated every month with new data but the same format.
    On another tab, I have each month in a different column, several lines
    I want for each column/month and each line to look for the corresponding data in the raw data table.

    What I have tried : pasting the table for each month below the one for the previous month with adding "Month" column. I was thinking about using the Vlookup function however I can look for only one attribute and here I need to look for several ones (the right month, then the right line/metric, then the right column/segment).
    I also thought using a pivot table with the month as filter but then I'm not sure how to look in the pivot table with a specific filter/month...

    I attached a sample file so it's maybe more clear what I'm trying to do - basically to fill the different cells on the "Table" tab without having to link them one by one for each month.
    Is there a smart way to do this ?

    Many thanks !
    Attached Files Attached Files
    Last edited by Charlie98; 11-27-2019 at 06:40 AM.

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

    Re: Lookup several elements from a table updated each month

    You can use this array* formula in C3:

    =SUM(INDEX(Raw_Data!$E$2:$F$19,MATCH(1,(Raw_Data!$A$2:$A$19=C$1)*(Raw_Data!$B$2:$B$19=$B3),0),0))

    *Note that an array formula needs to be confirmed using the key combination of Ctrl-Shift-Enter (CSE), rather than the usual Enter.

    You might also need to use semicolons ( ; ) instead of commas ( , ) in your formula, depending on your regional settings.

    Then you can copy this across and down as required for Segments 3 and 4. For other segments, you will need to change the range reference shown in red in the formula (e.g. for Segments 1 and 2 this would become $C$2:$D$19 ), as there is no direct match between what you have in column A of the Table sheet and the headings on row 1 of the Raw_data sheet. Don't forget to use CSE again if you edit the formula.

    Hope this helps.

    Pete

+ 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. Designing a table with 3 elements
    By cjharwood in forum Excel General
    Replies: 2
    Last Post: 06-26-2019, 11:01 AM
  2. [SOLVED] Excel IsNumber Function treats array elements differently from range elements
    By Alan Beban in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 01-31-2018, 02:22 PM
  3. Constructing new table based on elements of a pre-existing table
    By the number cruncher in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 10-05-2017, 06:59 AM
  4. Sum and CountIF with table elements
    By BuZZarD73 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 02-24-2015, 12:04 PM
  5. Sum and CountIF with table elements
    By BuZZarD73 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 02-24-2015, 11:32 AM
  6. Resources for Using VBA to Manipulate Silverlight Elements like HTML Elements
    By linear_db in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 04-16-2013, 04:43 PM
  7. Make a list from a table of elements ?
    By Lucy Lastic in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-08-2005, 09:10 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