Sumif to Aggregate Data

acool

Board Regular
Joined
Feb 10, 2023
Messages
107
Office Version
  1. 365
Platform
  1. Windows
Hi Everyone,

I am currently trying to create a SUMIF formula that allows me to the aggregates the total values into the table below, using the the criteria of Quarter, as well as the values in Cell A17:A23. For example, for Net Quantity Q1, I would like the value of 5 to populate. For Gross Sales Q1 I would like 500 to populate etc. Any help in creating this formula would be greatly appreciated. Thank You!
1692721501903.png
 

Attachments

  • 1692721323379.png
    1692721323379.png
    39.1 KB · Views: 3

Excel Facts

Can a formula spear through sheets?
Use =SUM(January:December!E7) to sum E7 on all of the sheets from January through December
a sumifs() should work - BUT why the first row , dog toy

=SUMIFS($B$3:$I$3,$B$1:$I$1,B$16,$B$2:$I$2,$A17)

Book4
ABCDEFGHI
1q1q1q1q1q2q2q2q2
2netsalesdiscountreturnsnetsalesdiscountreturns
35102030110120140150
4
5
6
7
8
9
10
11
12
13
14
15
16q1q2
17net5110
18sales10120
19discount20140
20
Sheet1
Cell Formulas
RangeFormula
B17:C19B17=SUMIFS($B$3:$I$3,$B$1:$I$1,B$16,$B$2:$I$2,$A17)



Note: Images are difficult to see , and also requires that I input all the data myself, which means I may make an error, which is very time consuming, and from my point of view less likely to get a response, if a complicated spreadsheet. Plus we cannot see any of the formulas used.

Therefore -


A SMALL sample spreadsheet, around 10-20 rows, would help a lot here, with all sensitive data removed, and expected results mocked up and manually entered, with a few notes of explanation.

This will possibly enable a quicker and more accurate solution for you.

MrExcel has a tool called “XL2BB” that lets you post samples of your data and will allow us to copy/paste your sample data into our Excel spreadsheets, saving a lot of time.

You can also test to see if it works ok, in the "Test Here" forum.

OR if you cannot get XL2BB to work, or have restrictions on your PC

then put the sample spreadsheet onto a share

I only tend to goto OneDrive, Dropbox or google docs , as I'm never certain of other random share sites and possible virus.
Please make sure you have a representative data sample and also that the data has been desensitised, remember this site is open to anyone with internet access to see - so any sensitive / personal data should be removed

Make sure you set any share or google to share to everyone
 
Upvote 0
a sumifs() should work - BUT why the first row , dog toy

=SUMIFS($B$3:$I$3,$B$1:$I$1,B$16,$B$2:$I$2,$A17)

Book4
ABCDEFGHI
1q1q1q1q1q2q2q2q2
2netsalesdiscountreturnsnetsalesdiscountreturns
35102030110120140150
4
5
6
7
8
9
10
11
12
13
14
15
16q1q2
17net5110
18sales10120
19discount20140
20
Sheet1
Cell Formulas
RangeFormula
B17:C19B17=SUMIFS($B$3:$I$3,$B$1:$I$1,B$16,$B$2:$I$2,$A17)



Note: Images are difficult to see , and also requires that I input all the data myself, which means I may make an error, which is very time consuming, and from my point of view less likely to get a response, if a complicated spreadsheet. Plus we cannot see any of the formulas used.

Therefore -


A SMALL sample spreadsheet, around 10-20 rows, would help a lot here, with all sensitive data removed, and expected results mocked up and manually entered, with a few notes of explanation.

This will possibly enable a quicker and more accurate solution for you.

MrExcel has a tool called “XL2BB” that lets you post samples of your data and will allow us to copy/paste your sample data into our Excel spreadsheets, saving a lot of time.

You can also test to see if it works ok, in the "Test Here" forum.

OR if you cannot get XL2BB to work, or have restrictions on your PC

then put the sample spreadsheet onto a share

I only tend to goto OneDrive, Dropbox or google docs , as I'm never certain of other random share sites and possible virus.
Please make sure you have a representative data sample and also that the data has been desensitised, remember this site is open to anyone with internet access to see - so any sensitive / personal data should be removed

Make sure you set any share or google to shar
@etaf Apologies for the confusion. I misspoke in my original post. In this scenario, I am trying to sumif for all of the values that fall under the criteria for Quarter and the the values for the classification (Net Quantity, Net Sales, Etc.) So for Q1 Quantity, I would like the value to be 30. I would like the sum for all of the product titles. Thank You!
 
Upvote 0
can you just use row 7 ? instead of row 3 - as you have the total in the example anyway

=SUMIFS($B$7:$I$7,$B$1:$I$1,B$16,$B$2:$I$2,$A17)

special formatting - show text and then positive or negative number.xlsx
ABCDEFGHI
1q1q1q1q1q2q2q2q2
2netsalesdiscountreturnsnetsalesdiscountreturns
35102030110120140150
46112131112160
5722232120180
6
718236393342460140150
8
9
10
11
12
13
14
15
16q1q2
17net18342
18sales23460
19discount63140
Sheet2
Cell Formulas
RangeFormula
B7:I7B7=SUM(B3:B6)
B17:C19B17=SUMIFS($B$7:$I$7,$B$1:$I$1,B$16,$B$2:$I$2,$A17)
 
Upvote 0
or if you dont have a total , and what to add up all the rows

then try

=SUMPRODUCT(($B$1:$I$1=B$16)*($B$2:$I$2=$A17)*($B$3:$I$5))


special formatting - show text and then positive or negative number.xlsx
ABCDEFGHI
1q1q1q1q1q2q2q2q2
2netsalesdiscountreturnsnetsalesdiscountreturns
35102030110120140150
46112131112160
5722232120180
6
718236393342460140150
8
9
10
11
12
13
14
15
16q1q2
17net18342
18sales23460
19discount63140
20
21
22USE SUMPRODUCT
2318342
2423460
2563140
26
Sheet2
Cell Formulas
RangeFormula
B7:I7B7=SUM(B3:B6)
B17:C19B17=SUMIFS($B$7:$I$7,$B$1:$I$1,B$16,$B$2:$I$2,$A17)
B23:C25B23=SUMPRODUCT(($B$1:$I$1=B$16)*($B$2:$I$2=$A17)*($B$3:$I$5))
 
Upvote 0

Forum statistics

Threads
1,215,327
Messages
6,124,289
Members
449,149
Latest member
mwdbActuary

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top