Need help on a formula Maybe SumIfs

zone709

Well-known Member
Joined
Mar 1, 2016
Messages
2,079
Office Version
  1. 365
Platform
  1. Windows
So i made an example sheet below. I need the total gross from Columns E from the ID's from Column A ,Total Gross by different class codes.

You can see if i am thinking right maybe the formula goes in Column H. If i pull the formula down in Column H to fill in Columns F ,G, H. You can see F has id number 5 3x, While G has 3 different class codes. Sometimes it can be 4 or 5. and H with the totals of ID 5 by class code in H. The reason why I'm looking for something like this is because my sheet goes down to line 3000 lines of data. So i am going through each ID number for totals and different class codes. Taking me forever. Any help would be great as this Formula is very complicated for me. Employee ID Starts at Column A.

Excel 2016 (Windows) 32 bit
A
B
C
D
E
F
G
H
1
employee_ID
first_name
last_name
class_code
gross_employee_pay
2
ResultsResults Formula
3
5​
JoeSYard
4280.00​
5​
Yard
$ 25,780.00​
4
5​
JoeSSupervisor
4280.00​
5​
Supervisor
$ 31,840.50​
5
5​
JoeSSupervisor
4761.50​
5​
Concrete
$ 15,876.00​
6
5​
JoeSSupervisor
5243.00​
9​
Yard
$ 8,050.00​
7
5​
JoeSYard
4280.00​
9​
Supervisor
$ 9,822.00​
8
5​
JoeSYard
6244.00​
9​
Concrete
$ 3,560.00​
9
5​
JoeSSupervisor
6328.00​
10
5​
JoeSYard
5992.00​
11
5​
JoeSSupervisor
5656.00​
12
5​
JoeSYard
4984.00​
13
5​
JoeSConcrete
4816.00​
14
5​
JoeSConcrete
5656.00​
15
5​
JoeSConcrete
5404.00​
16
5​
JoeSSupervisor
5572.00​
17
9​
AlexSYard
2350.00​
18
9​
AlexSConcrete
3560.00​
19
9​
AlexSSupervisor
4250.00​
20
9​
AlexSYard
2350.00​
21
9​
AlexSYard
3350.00​
Sheet: Sheet1
 

Excel Facts

Can you AutoAverage in Excel?
There is a drop-down next to the AutoSum symbol. Open the drop-down to choose AVERAGE, COUNT, MAX, or MIN
Try:

Book1
ABCDEFGH
10
2employee_IDfirst_namelast_nameclass_codegross_employee_pay
3ResultsResultsFormula
45JoeSYard4280.005Yard25780
55JoeSSupervisor4280.005Supervisor31840.5
65JoeSSupervisor4761.505Concrete15876
75JoeSSupervisor5243.009Yard8050
85JoeSYard4280.009Concrete3560
95JoeSYard6244.009Supervisor4250
105JoeSSupervisor6328.00
115JoeSYard5992.00
125JoeSSupervisor5656.00
135JoeSYard4984.00
145JoeSConcrete4816.00
155JoeSConcrete5656.00
165JoeSConcrete5404.00
175JoeSSupervisor5572.00
189AlexSYard2350.00
199AlexSConcrete3560.00
209AlexSSupervisor4250.00
219AlexSYard2350.00
229AlexSYard3350.00
23
Sheet1
Cell Formulas
RangeFormula
F4:H9F4=LET(a,CHOOSE({1,2},A4:A22,D4:D22),b,UNIQUE(a),c,INDEX(b,0,1),d,INDEX(b,0,2),CHOOSE({1,2,3},c,d,SUMIFS(E4:E22,A4:A22,c,D4:D22,d)))
Dynamic array formulas.
 
Upvote 0
Solution
Works Thank you

Try:

Book1
ABCDEFGH
10
2employee_IDfirst_namelast_nameclass_codegross_employee_pay
3ResultsResultsFormula
45JoeSYard4280.005Yard25780
55JoeSSupervisor4280.005Supervisor31840.5
65JoeSSupervisor4761.505Concrete15876
75JoeSSupervisor5243.009Yard8050
85JoeSYard4280.009Concrete3560
95JoeSYard6244.009Supervisor4250
105JoeSSupervisor6328.00
115JoeSYard5992.00
125JoeSSupervisor5656.00
135JoeSYard4984.00
145JoeSConcrete4816.00
155JoeSConcrete5656.00
165JoeSConcrete5404.00
175JoeSSupervisor5572.00
189AlexSYard2350.00
199AlexSConcrete3560.00
209AlexSSupervisor4250.00
219AlexSYard2350.00
229AlexSYard3350.00
23
Sheet1
Cell Formulas
RangeFormula
F4:H9F4=LET(a,CHOOSE({1,2},A4:A22,D4:D22),b,UNIQUE(a),c,INDEX(b,0,1),d,INDEX(b,0,2),CHOOSE({1,2,3},c,d,SUMIFS(E4:E22,A4:A22,c,D4:D22,d)))
Dynamic array formulas.


Book1
ABCDEFGH
10
2employee_IDfirst_namelast_nameclass_codegross_employee_pay
3ResultsResultsFormula
45JoeSYard4280.005Yard25780
55JoeSSupervisor4280.005Supervisor31840.5
65JoeSSupervisor4761.505Concrete15876
75JoeSSupervisor5243.009Yard8050
85JoeSYard4280.009Concrete3560
95JoeSYard6244.009Supervisor4250
105JoeSSupervisor6328.00
115JoeSYard5992.00
125JoeSSupervisor5656.00
135JoeSYard4984.00
145JoeSConcrete4816.00
155JoeSConcrete5656.00
165JoeSConcrete5404.00
175JoeSSupervisor5572.00
189AlexSYard2350.00
199AlexSConcrete3560.00
209AlexSSupervisor4250.00
219AlexSYard2350.00
229AlexSYard3350.00
23
Sheet1
Cell Formulas
RangeFormula
F4:H9F4=LET(a,CHOOSE({1,2},A4:A22,D4:D22),b,UNIQUE(a),c,INDEX(b,0,1),d,INDEX(b,0,2),CHOOSE({1,2,3},c,d,SUMIFS(E4:E22,A4:A22,c,D4:D22,d)))
Dynamic array formulas.
 
Upvote 0

Forum statistics

Threads
1,214,653
Messages
6,120,751
Members
448,989
Latest member
mariah3

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