+ Reply to Thread
Results 1 to 7 of 7

Formula to sum up in different columns

  1. #1
    Registered User
    Join Date
    07-14-2020
    Location
    London
    MS-Off Ver
    MS Office Professional Plus 2019
    Posts
    3

    Formula to sum up in different columns

    Hi all,

    I need to come up with a formula that sums up the total positive numbers for each colour in one column and the total negative numbers for each colour in a separate column. So the Totals in columns C and D should show sums of numbers (positive or negative) between two Totals in column B. I've been struggling with this little issue all morning, so any help would be much appreciated.

    Thanks!
    Attached Files Attached Files

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Ipswich, England
    MS-Off Ver
    MS 365 Business (Win 10 - Work) & MS 365 Subscription Insider (Win 10 - Home)
    Posts
    41,353

    Re: Formula to sum up in different columns

    Welcome to the forum.

    Like this perhaps:

    Excel 2016 (Windows) 32 bit
    D
    E
    1
    Required data
    2
    Total positive Total negative
    3
    =IF($B3>0,$B3,0)
    =IF($B3<0,$B3,0)
    Sheet: Sheet1
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!

    Forum Rules (updated September 2018): please read them here.
    How to use the Power Query code you've been given: help here. More about the Power suite here.
    Don't forget to say "thank you" to those who have helped you in your thread. If you wish, you can also reward them by clicking on their reputation star bottom left.

  3. #3
    Registered User
    Join Date
    07-14-2020
    Location
    London
    MS-Off Ver
    MS Office Professional Plus 2019
    Posts
    3

    Re: Formula to sum up in different columns

    Thank you!

    Since there are hundreds of "colours", I need D7 and E7, D14 and E14, etc. to show the totals for the color above. So the formula should include that if A7 is "Total", then I get the total of the positive/negative numbers between B3 and B6, else I get the positive/negative number as you suggested. However, I'm not sure how to indicate in the formula on what cells should be summed up in "Total".

  4. #4
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Ipswich, England
    MS-Off Ver
    MS 365 Business (Win 10 - Work) & MS 365 Subscription Insider (Win 10 - Home)
    Posts
    41,353

    Re: Formula to sum up in different columns

    OK - provide a more representative set of sample data that shows us what you really want and I'll take another look. I don't do guessing games - sorry.

  5. #5
    Forum Expert XLent's Avatar
    Join Date
    10-13-2010
    Location
    UK
    MS-Off Ver
    various
    Posts
    1,889

    Re: Formula to sum up in different columns

    Quote Originally Posted by Deria View Post
    ...I need D7 and E7, D14 and E14, etc. to show the totals for the color above.
    So, based on your sample file / values, something like:

    Formula: copy to clipboard
    Please Login or Register  to view this content.

  6. #6
    Registered User
    Join Date
    07-14-2020
    Location
    London
    MS-Off Ver
    MS Office Professional Plus 2019
    Posts
    3

    Re: Formula to sum up in different columns

    That's exactly what I needed! Thank you!

  7. #7
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Ipswich, England
    MS-Off Ver
    MS 365 Business (Win 10 - Work) & MS 365 Subscription Insider (Win 10 - Home)
    Posts
    41,353

    Re: Formula to sum up in different columns

    If that takes care of your original question, please select Thread Tools from the menu link above and mark this 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)

Similar Threads

  1. Replies: 6
    Last Post: 09-21-2016, 04:21 PM
  2. Formula(s) to Split Text String Across Columns Using Columns as Seperator
    By WaylettChris in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 05-24-2016, 01:13 PM
  3. Replies: 2
    Last Post: 07-08-2014, 08:53 AM
  4. Replies: 0
    Last Post: 05-22-2014, 08:10 AM
  5. Replies: 6
    Last Post: 05-30-2013, 04:58 PM
  6. Increment columns in INDEX and MATCH formula - ROWS and COLUMNS
    By nickmangan in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 09-06-2012, 10:38 AM
  7. Formula to align two columns with nearly similar text and attached numeric columns
    By Benefits Recon in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 01-27-2012, 12:03 AM

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