+ Reply to Thread
Results 1 to 5 of 5

Sum of rows based on condition

  1. #1
    Registered User
    Join Date
    07-01-2020
    Location
    Yerevan
    MS-Off Ver
    2010
    Posts
    44

    Sum of rows based on condition

    Hi All,

    I have an excel file which shows Sender Receiver and the Amount sent.

    I would like to sum the amounts in Column D, when the sender and receiver in the row are the same.

    For example
    HTML Code:

    Sender Receiver Amount

    Row 1 Company A Company B 500
    Row 2 Company A Company C 1000
    Row 3 Company A Company B 2000

    So, it will sum Row 1 and Row 3 only (as sender is the same and recevier is the same) and output will be as follows:

    HTML Code:

    Sender Receiver Amount

    Row 1 Company A Company B 2500 (2000+500)
    Row 2 Company A Company C 1000


    So, after this I will have smaller number of rows showing sender, receiver and consolidated amounts.

    Will be glad to hear your suggestions.

    thank you
    Attached Files Attached Files
    Last edited by lilit2222; 10-02-2020 at 03:46 AM.

  2. #2
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2402
    Posts
    13,443

    Re: Sum of rows based on condition

    Administrative note

    Welcome to the forum

    in your haste to solve your problem, you probably missed the yellow banner advising how to get answers faster by posting a sheet ?

    Please take a moment to read it and attach a sheet accordingly.

    Thanks you for helping us help you

  3. #3
    Registered User
    Join Date
    07-01-2020
    Location
    Yerevan
    MS-Off Ver
    2010
    Posts
    44

    Re: Sum of rows based on condition

    I have edited the original post and attached the workbook with sample data.
    Sheet 1- row data
    Sheet 2- the expected output

  4. #4
    Forum Moderator davesexcel's Avatar
    Join Date
    02-19-2006
    Location
    Regina
    MS-Off Ver
    MS 365
    Posts
    13,474

    Re: Sum of rows based on condition

    Try sumifs()
    Formula: copy to clipboard
    Please Login or Register  to view this content.

  5. #5
    Valued Forum Contributor
    Join Date
    06-27-2010
    Location
    sYRIA
    MS-Off Ver
    Excel 2013
    Posts
    669

    Re: Sum of rows based on condition

    Hi
    May be?
    Please Login or Register  to view this content.

+ 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. [SOLVED] Delete Rows Based on Condition
    By gxm100 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 12-28-2018, 12:27 PM
  2. Macro copies rows based on condition, BUT rows copy in Wrong order. PLEASE HELP!
    By JAllard1990 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-16-2014, 04:33 PM
  3. How to delete rows based on a met condition between two rows
    By dijimbob in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 01-23-2014, 05:11 PM
  4. Need to insert Rows Based on a Condition
    By skandkamat in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 04-17-2013, 12:06 AM
  5. Sum last n rows based on condition (SUMIF won't cut it)
    By LondonJames in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 01-16-2012, 02:35 PM
  6. Delete rows based on condition
    By elocin17 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 01-12-2012, 12:35 PM
  7. [SOLVED] Hide rows based on a condition
    By KimberlyH in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-29-2006, 04:10 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