+ Reply to Thread
Results 1 to 6 of 6

Match Multiple Values & Return Sum of Multiple Columns?

  1. #1
    Registered User
    Join Date
    01-24-2022
    Location
    Kettering, OH
    MS-Off Ver
    365
    Posts
    11

    Match Multiple Values & Return Sum of Multiple Columns?

    Hello,

    I have a workbook with 2 worksheets, Last_Operation & Item_Matrix.
    Last_Operation has a pivot table (columns Job, Item, Qty) with multiple item # (column A) & each's last operation # (column B) per job. See attachment for sample.
    Item_Matrix contains multiple item # in column B (duplicated in 3 row groups) with operation # on the 3rd row in columns F:Y for each item. See attachment for sample.
    What I am seeking is the sum of the Item_Matrix worksheet's Run Durations for the remaining operation # per each job on the Last_Operation pivot table.

    For example:
    Item # 1401400-001
    Last_Operation = # 10
    Item_Matrix shows remaining operations are 20, 25, 30, 40, 50, 60.
    Sum of Run Durations for these operations is 1.18 (0.58 (Operation 30) + 0.5 (Operation 40) + 0.1 (Operation 50)).
    ^This sum of Run Durations for each job is what I'm struggling to generate.

    Please help me.
    Thank you.

    EDIT:
    Upon some attempts, I'm thinking referring to the pivot table may not work. Correct me if I'm wrong.
    Please find attachment of the source data on worksheet JobOperations. Column BI is a helper column to filter the jobs by a WC #.

    EDIT:
    Attached a sample workbook.
    Worksheet Last_Operation has a column with cell fill yellow that shows what the expected results to be. The job's perhaps the best example.
    Attached Images Attached Images
    Attached Files Attached Files
    Last edited by Hites_05; 04-25-2023 at 09:45 AM. Reason: Added sample workbook.

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,836

    Re: Match Multiple Values & Return Sum of Multiple Columns?

    There are instructions at the top of the page explaining how to attach your sample workbook. Screenshots are of little practical use as we cannot manipulate them.

    A good sample workbook has just 10-20 rows of representative data that has been desensitised. It also has expected results mocked up, worked examples where required, relevant cells highlighted and a few explanatory notes.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  3. #3
    Registered User
    Join Date
    01-24-2022
    Location
    Kettering, OH
    MS-Off Ver
    365
    Posts
    11

    Re: Match Multiple Values & Return Sum of Multiple Columns?

    Ali,

    Thank you.
    I've edited the OP to include a sample workbook & some additional information.
    Last edited by AliGW; 04-25-2023 at 10:03 AM. Reason: Please do NOT quote unnecessarily!

  4. #4
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,836

    Re: Match Multiple Values & Return Sum of Multiple Columns?

    Thanks. So you are expecting all 0 apart from the last result - is this correct?

  5. #5
    Registered User
    Join Date
    01-24-2022
    Location
    Kettering, OH
    MS-Off Ver
    365
    Posts
    11

    Re: Match Multiple Values & Return Sum of Multiple Columns?

    Quote Originally Posted by AliGW View Post
    Thanks. So you are expecting all 0 apart from the last result - is this correct?
    Ali,

    That is correct. It's not the best example, as we'd hope to have multiple jobs in process with operations with run durations >0 still remaining, but this is the data I'm currently working with. Luckily, at least the last job still has operations with run durations >0 still remaining.
    Thank you for confirming understanding.

  6. #6
    Forum Expert CheeseSandwich's Avatar
    Join Date
    12-22-2021
    Location
    Kent, England
    MS-Off Ver
    365 - 2402-17328.20068
    Posts
    1,361

    Re: Match Multiple Values & Return Sum of Multiple Columns?

    Still not sure i understand but i had the below in cell J2 of the Last Operation sheet:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Then i had this in cell L2 of the same sheet dragged down:
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    If things don't change they stay the same

+ 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: 1
    Last Post: 02-12-2021, 07:21 PM
  2. Replies: 3
    Last Post: 08-17-2019, 05:53 AM
  3. Replies: 4
    Last Post: 05-12-2014, 07:10 PM
  4. [SOLVED] How to match data (ID value) in 2 columns in two worksheets, and return multiple values
    By awonghope in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 08-01-2013, 05:58 PM
  5. [SOLVED] Lookup match index multiple values return other columns
    By martypocock in forum Excel Formulas & Functions
    Replies: 25
    Last Post: 11-07-2012, 10:57 PM
  6. Return Multiple Values with multiple rows & multiple columns
    By sachin parab in forum Excel General
    Replies: 2
    Last Post: 11-05-2012, 10:21 AM
  7. Replies: 2
    Last Post: 06-29-2011, 01:36 PM

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