+ Reply to Thread
Results 1 to 4 of 4

Sumproduct combined with Sum

  1. #1
    Registered User
    Join Date
    07-10-2006
    Posts
    18

    Sumproduct combined with Sum

    I'm looking for the syntax to multiply a column of Rates (eg A3:A5)
    by the sums of selected values (eg C3:D5) in the row for each Rate.

    A B C D E
    1 Hrs Hrs Hrs Hrs
    2 Rate Jan Feb Mar Apr
    3 100 10 40 70 75
    4 200 20 50 80 85
    5 300 30 60 90 95

    The result would equal A3*sum(C3:D3)+A4*sum(C4:D4)+A5*sum(C5:D5)

    I know this can be done by using separate sum and sumproduct formulas,
    but I'm looking for a single formula, since I need to use it in many instances in a very large spreadsheet.

    The following attempt, of course, does not work:

    =SUMPRODUCT(A3:A5,SUM(C3:D3):SUM(C5:D5))

    Any assistance will be greatly appreciated.

  2. #2
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: Sumproduct combined with Sum

    It's unclear how you intend to determine "selected values" but in terms of the specifics of the ex.

    Please Login or Register  to view this content.
    Quote Originally Posted by Exceler
    I'm looking for a single formula, since I need to use it in many instances in a very large spreadsheet
    in which case you should be avoiding SUMPRODUCT (it's very inefficient) - you would be better creating a suitable Product calculation on each line and Summing accordingly.

  3. #3
    Registered User
    Join Date
    07-10-2006
    Posts
    18

    Re: Sumproduct combined with Sum

    Thanks, that did it. I need to study up on the logic behind the syntax used in Excel functions.

  4. #4
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: Sumproduct combined with Sum

    The SUMPRODUCT link in my sig. outlines the function (and alternative syntax) in more detail.

    To reiterate though - by the sounds of it you should be looking to avoid SUMPRODUCT
    (less elegance in this instance is likely to lead to far better calculation performance overall)

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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