+ Reply to Thread
Results 1 to 4 of 4

Trying to sum up values based on 2 conditions

Hybrid View

  1. #1
    Registered User
    Join Date
    03-29-2012
    Location
    Santiago de Chile
    MS-Off Ver
    Excel 2007
    Posts
    36

    Trying to sum up values based on 2 conditions

    Hi Community,
    I am desperatly looking for a formula which can help me. In the Excel sheet attached to this post there is information about executive compensation included. The important stuff are the YEARS, the column labelled CASH COMPENSATION and the column labelled CUSIP. My problem is that i have several executives being compensated during one year according to one company (see CUSIP code). I need however the total Cash compensation during one year according to one CUSIP (company). In the end i would like to have an excel file with just one Compensation value, one CUSIP value and one value for Year, so basically the sum of compensation according to CUSIP and YEAR.

    It would be great if the formula would work for several years and several companies (CUSIPS) as i have more than 100 companies over 5 years.
    I hope i stated my problem as clear as possible and somebody is willing to help me on that. Thank you very much in advance.

    Paul
    Attached Files Attached Files
    Last edited by slacknoise; 03-29-2012 at 06:47 AM.

  2. #2
    Forum Expert Cutter's Avatar
    Join Date
    05-24-2004
    Location
    Ontario,Canada
    MS-Off Ver
    Excel 2010
    Posts
    6,451

    Re: Trying to sum up values based on 2 conditions

    If I understand you correctly:

    Try the SUMIFS() function - with the year you want in G1 & the CUSIP in H1 use:
    =SUMIFS(E:E,A:A,G1,B:B,H1)

    Here's a link to read about the function: http://www.excelfunctions.net/Excel-...-Function.html

  3. #3
    Registered User
    Join Date
    03-29-2012
    Location
    Santiago de Chile
    MS-Off Ver
    Excel 2007
    Posts
    36

    Re: Trying to sum up values based on 2 conditions

    I dont really now why you included "G1" and "H1". Anyway i replaced "G1" with "A1" and consequently "H1" with "B1" and it works fine now. Thank you very much for the fast reply it works perfectly now. kind regards

  4. #4
    Forum Expert Cutter's Avatar
    Join Date
    05-24-2004
    Location
    Ontario,Canada
    MS-Off Ver
    Excel 2010
    Posts
    6,451

    Re: Trying to sum up values based on 2 conditions

    I used G1 and H1 as "holders" so the formula would be flexible for use in what I assume is a much larger file. That way you could change the input values in those 2 cells to get the totals from your data for various inputs in those 2 cells.
    Anyway, glad it works for you. Please mark your thread as SOLVED.

+ 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