+ Reply to Thread
Results 1 to 12 of 12

SUMIFS Calculation for Cumulative Annual Wages

  1. #1
    Forum Contributor
    Join Date
    07-31-2018
    Location
    London, England
    MS-Off Ver
    MS Office 365
    Posts
    104

    SUMIFS Calculation for Cumulative Annual Wages

    Howdy all,

    I have designed a basic Excel spreadsheet to calculate my real wages, based on my monthly salary and the host of different deductions and thresholds the UK government has for me that looks something like this (don't worry, it's all dummy data):
    Table.png

    I am trying to create a column to calculate the cumulative annual wage after deductions, however, my SUMIFS formula is incorrectly constructed and I cannot understand where to go from here. The logic I would like the formula to follow is as follows:

    "For Year = X, then SUM all 'Monthly After Deductions' values in X" where X is the corresponding year of that row, which will dynamically change as more rows are added to the table for each new month.

    In this example, this would make the first and second rows in that column equal to £2,811.78, and the third row onward in that column equal to £8,016.26.

    I would greatly appreciate if anyone could help me structuring a formula that will perform such an action. I have attached this dummy database below for your further understanding.

    Thank you very much in advance for your help.

    EDIT: Solved now. /closed
    Attached Files Attached Files
    Last edited by doubleuson; 06-01-2020 at 02:33 PM.

  2. #2
    Forum Expert
    Join Date
    09-07-2014
    Location
    Israel
    MS-Off Ver
    office 365 for MAC
    Posts
    3,105

    Re: SUMIFS Calculation for Cumulative Annual Wages

    Try this in E3 and down:

    =SUMIFS([Monthly After Deductions],[Year],[@Year])
    Attached Files Attached Files

  3. #3
    Forum Guru Bo_Ry's Avatar
    Join Date
    09-10-2018
    Location
    Thailand
    MS-Off Ver
    MS 365
    Posts
    7,211

    Re: SUMIFS Calculation for Cumulative Annual Wages

    Maybe try at E3

    =SUMIFS(Taxes1[Monthly After Deductions],Taxes1[Year],B3)

  4. #4
    Forum Contributor
    Join Date
    07-31-2018
    Location
    London, England
    MS-Off Ver
    MS Office 365
    Posts
    104

    Re: SUMIFS Calculation for Cumulative Annual Wages

    Quote Originally Posted by belinda200 View Post
    Try this in E3 and down:

    =SUMIFS([Monthly After Deductions],[Year],[@Year])
    This worked a charm. Looks like I made a right mess of my attempt at the formula. Who knew it could be so simple. Thanks very much!

  5. #5
    Forum Expert ben_hensel's Avatar
    Join Date
    01-26-2012
    Location
    Northeast USA
    MS-Off Ver
    Office 365
    Posts
    2,043

    Re: SUMIFS Calculation for Cumulative Annual Wages

    I don't see where exactly you want it but the function you're asking for is pretty simple:
    Please Login or Register  to view this content.
    I've hardcoded the year reference as 2019 in red, but you could make that a cell reference or whatever.

    Note I only used SUMIF not SUMIFS, which has marginally different syntax, assuming you wanted to add more boolean tests:
    Please Login or Register  to view this content.
    The case I'm imagining you'd need to go to SUMIFS, is you've got year+month in the same cell so you have to bound it as SUMIFS(pay, date_range, " >= start of this year", date_range "< start of next year") or something like that.

    Also this is unsolicited, but I think you could TAX and NI columns into simple lookup tables instead of that horrid nest of IF statements.
    Click the [* Add Reputation] Button to thank people for help!
    Post Attachment: Click [Go Advanced] under the reply box; then click [Manage Attachments] to launch the attachments dialogue.
    Mark Thread Solved: Go to the top of the first post; Select [Thread Tools] dropdown; Pick the [Mark thread as Solved] option.

  6. #6
    Forum Contributor
    Join Date
    07-31-2018
    Location
    London, England
    MS-Off Ver
    MS Office 365
    Posts
    104

    Re: SUMIFS Calculation for Cumulative Annual Wages

    Quote Originally Posted by ben_hensel View Post
    Also this is unsolicited, but I think you could TAX and NI columns into simple lookup tables instead of that horrid nest of IF statements.
    I would if I knew how to go about it. They get quite fiddly but I was going to leave this part for when the Tax and NI rates change in April next year 😂

    If you could give me a solid nudge in the right direction (ie an example for NI, I can then reapply it for the more complex tax), would appreciate.

    Thanks.

  7. #7
    Forum Guru Bo_Ry's Avatar
    Join Date
    09-10-2018
    Location
    Thailand
    MS-Off Ver
    MS 365
    Posts
    7,211

    Re: SUMIFS Calculation for Cumulative Annual Wages

    Please try at
    H3
    =SUMPRODUCT(TEXT(G3-N(+Rates_20_21!$D$3:$D$6),"General;\0;0")*(Rates_20_21!$F$3:$F$6-N(+Rates_20_21!$F$2:$F$5)))

    I3
    =SUMPRODUCT(TEXT(G3-N(+Rates_20_21!$D$9:$D$11),"General;\0;0")*(Rates_20_21!$F$9:$F$11-N(+Rates_20_21!$F$8:$F$10)))
    Attached Files Attached Files

  8. #8
    Forum Contributor
    Join Date
    07-31-2018
    Location
    London, England
    MS-Off Ver
    MS Office 365
    Posts
    104

    Re: SUMIFS Calculation for Cumulative Annual Wages

    Quote Originally Posted by Bo_Ry View Post
    Please try at
    H3
    =SUMPRODUCT(TEXT(G3-N(+Rates_20_21!$D$3:$D$6),"General;\0;0")*(Rates_20_21!$F$3:$F$6-N(+Rates_20_21!$F$2:$F$5)))

    I3
    =SUMPRODUCT(TEXT(G3-N(+Rates_20_21!$D$9:$D$11),"General;\0;0")*(Rates_20_21!$F$9:$F$11-N(+Rates_20_21!$F$8:$F$10)))
    Yeah, all works great! Thanks very much.

  9. #9
    Forum Expert ben_hensel's Avatar
    Join Date
    01-26-2012
    Location
    Northeast USA
    MS-Off Ver
    Office 365
    Posts
    2,043

    Re: SUMIFS Calculation for Cumulative Annual Wages

    Quote Originally Posted by doubleuson View Post
    If you could give me a solid nudge in the right direction (ie an example for NI, I can then reapply it for the more complex tax), would appreciate.
    Ugh I nerd-sniped myself because it's a bracket calculation instead of a simple lookup, now that I approach again.

    Can still be simplified though by burying sophisticated logic in SUMPRODUCT
    Please Login or Register  to view this content.
    Second column is (Income - bracket row) * third column = (row percentage) and use the first column to force negative results to zero.
    (Eg with 1666 income, the third bracket row is 16666 - 4156 < 0, so you tell it to ignore the zero number.

  10. #10
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 v 2404
    Posts
    13,406

    Re: SUMIFS Calculation for Cumulative Annual Wages

    @ ben_hensel

    nerd-snipe ?

    LOL. Loved it.

    Sounds like a snappy name for a competing forum.
    Dave

  11. #11
    Valued Forum Contributor
    Join Date
    02-06-2013
    Location
    Germany
    MS-Off Ver
    365
    Posts
    498

    Re: SUMIFS Calculation for Cumulative Annual Wages

    lul
    I am gonna steal that term, too!

  12. #12
    Forum Expert ben_hensel's Avatar
    Join Date
    01-26-2012
    Location
    Northeast USA
    MS-Off Ver
    Office 365
    Posts
    2,043

    Re: SUMIFS Calculation for Cumulative Annual Wages

    Quote Originally Posted by FlameRetired View Post
    nerd-snipe ?

    LOL. Loved it.
    Can't take credit for this turn of phrase, it's from XKCD:
    Attached Images Attached Images

+ 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: 13
    Last Post: 10-29-2017, 06:00 AM
  2. [SOLVED] Find out the time between 1st day to next day for **** wages calculation
    By vrumapathy in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 03-04-2015, 03:22 AM
  3. [SOLVED] Cumulative total sales with annual growth
    By donkeybusiness in forum Excel General
    Replies: 17
    Last Post: 01-07-2015, 10:53 AM
  4. Annual cost calculation based on changes.
    By sekharyadav in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 04-21-2013, 01:30 AM
  5. [SOLVED] Calculation of annual leave
    By youngjeesu in forum Excel General
    Replies: 3
    Last Post: 08-10-2012, 01:08 AM
  6. Annual cumulative interest
    By haloperidal in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 06-28-2012, 11:31 AM
  7. Replies: 0
    Last Post: 08-29-2005, 11:04 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