SUMIFS on unique rows

mimi_nyc

New Member
Joined
Jan 18, 2024
Messages
5
Office Version
  1. 365
  2. 2010
Platform
  1. Windows
Hello,
I'm working a commission report template and running into duplicate values issue. We calculate commission based on the $ value of deals closed by sales reps, and the sales manager get commission on total deal values of their direct reports. Sometimes two members of the same team share a deal so each sales rep will get commission on that deal, however their sales manager should only get credit ONCE. I use SUMIFS because I have to look at multiple criteria before rolling up the revenue (like sales name, time period, etc), but when I do SUMIFS, excel rolls up the revenue twice from both reps. the desired outcome is to count that deal only once. We have unique contract #s that we can use to identify dupes. Attached sample data on gdrive . Please help 🙏

SAMPLE DATA - SUMIFS

1705677153739.png
 

Excel Facts

Why does 9 mean SUM in SUBTOTAL?
It is because Sum is the 9th alphabetically in Average, Count, CountA, Max, Min, Product, StDev.S, StDev.P, Sum, VAR.S, VAR.P.
What are the values that uniquely identify one deal? (If this were a database, I would be asking you what is the key.) All the rows here have the same contract number, so that's probably not it. Does the Period determine the deal? If so, it looks like the first three rows are all the same deal, with three partners and two managers.

Can you elaborate more on your business model?
 
Upvote 0
What are the values that uniquely identify one deal? (If this were a database, I would be asking you what is the key.) All the rows here have the same contract number, so that's probably not it. Does the Period determine the deal? If so, it looks like the first three rows are all the same deal, with three partners and two managers.

Can you elaborate more on your business model?
Hi! we're in advertising business, so the closed deals are advertising campaign that run over time, say 3 months but we recognize revenue monthly based on the time period between start of advertising campaign to end of campaign. in this case, the looney campaign total was $150K, with $100K allocated in 2024. the key/unique identifier is the contract number. In this case, sales manager should be paid once for 2024 for that same contract # for where he is listed as the manager. he is now getting paid x2 because two of his members share the same contract.
In a larger set, he would have more reps rolling to him, and multiple opportunities thats why I added the manager as identifier to sumup all of the direct reports revenue. I hope that makes sense...I didnt finish my coffee today
 
Upvote 0
Hello,
I'm working a commission report template and running into duplicate values issue. We calculate commission based on the $ value of deals closed by sales reps, and the sales manager get commission on total deal values of their direct reports. Sometimes two members of the same team share a deal so each sales rep will get commission on that deal, however their sales manager should only get credit ONCE. I use SUMIFS because I have to look at multiple criteria before rolling up the revenue (like sales name, time period, etc), but when I do SUMIFS, excel rolls up the revenue twice from both reps. the desired outcome is to count that deal only once. We have unique contract #s that we can use to identify dupes. Attached sample data on gdrive . Please help 🙏

SAMPLE DATA - SUMIFS

View attachment 105375
Is it possible to do SUMIFs and add a criteria to only some the contract + period once? i.e sum if contract is unique and manager = Mr Peanut, Period = 2024 and
 
Upvote 0
Hi! we're in advertising business, so the closed deals are advertising campaign that run over time, say 3 months but we recognize revenue monthly based on the time period between start of advertising campaign to end of campaign. in this case, the looney campaign total was $150K, with $100K allocated in 2024. the key/unique identifier is the contract number. In this case, sales manager should be paid once for 2024 for that same contract # for where he is listed as the manager. he is now getting paid x2 because two of his members share the same contract.
In a larger set, he would have more reps rolling to him, and multiple opportunities thats why I added the manager as identifier to sumup all of the direct reports revenue. I hope that makes sense...I didnt finish my coffee today

@6StringJazzer sorry forgot to tag you to my response. I'm new to this forum
 
Upvote 0
Based on your data, is this what you're after?
Book1
ABCDEFG
1Share PartnerManagerOpportunity NameContract #PeriodYearRevenue
2Mickey MouseMr PeanutLooney Tunes Browdway 2004--2024$100,000
3Minnie MouseMr PeanutLooney Tunes Browdway 2004--2024$100,000
4Duffy DuckScooby DooLooney Tunes Browdway 2004--2024$100,000
5Mickey MouseMr PeanutLooney Tunes Browdway 2004--2023$50,000
6Minnie MouseMr PeanutLooney Tunes Browdway 2004--2023$50,000
7Duffy DuckScooby DooLooney Tunes Browdway 2004--2023$50,000
8
9
10NamePeriodBooked Revenue
11Mickey Mouse2024$100,000
12Minnie Mouse2024$100,000
13Duffy Duck2024$100,000
14Mr Peanut2024$200,000
15Scooby Doo2024$100,000
Sheet1
Cell Formulas
RangeFormula
C11:C15C11=SUMPRODUCT(--($A$2:$A$7=$A11)--($B$2:$B$7=$A11),--($F$2:$F$7=B11),$G$2:$G$7)

Thanks
 
Upvote 0
.. or is it this?

24 01 20.xlsm
ABCDEFG
1Share PartnerManagerOpportunity NameContract #PeriodYearRevenue
2Mickey MouseMr PeanutLooney Tunes Browdway 20041182024-2024100,000.00
3Minnie MouseMr PeanutLooney Tunes Browdway 20041182024-2024100,000.00
4Duffy DuckScooby DooLooney Tunes Browdway 20041182024-2024100,000.00
5Mickey MouseMr PeanutLooney Tunes Browdway 20041182024-202350,000.00
6Minnie MouseMr PeanutLooney Tunes Browdway 20041182024-202350,000.00
7Duffy DuckScooby DooLooney Tunes Browdway 20041182024-202350,000.00
8
9
10NamePeriodBooked Revenue
11Mickey Mouse2024100,000.00
12Minnie Mouse2024100,000.00
13Duffy Duck2024100,000.00
14Mr Peanut2024100,000.00
15Scooby Doo2024100,000.00
Revenue
Cell Formulas
RangeFormula
C11:C15C11=SUM(TAKE(UNIQUE(FILTER(D$2:G$7,((B$2:B$7=A11)+(A$2:A$7=A11))*(F$2:F$7=B11))),,-1))
 
Upvote 0
Solution
.. or is it this?

24 01 20.xlsm
ABCDEFG
1Share PartnerManagerOpportunity NameContract #PeriodYearRevenue
2Mickey MouseMr PeanutLooney Tunes Browdway 20041182024-2024100,000.00
3Minnie MouseMr PeanutLooney Tunes Browdway 20041182024-2024100,000.00
4Duffy DuckScooby DooLooney Tunes Browdway 20041182024-2024100,000.00
5Mickey MouseMr PeanutLooney Tunes Browdway 20041182024-202350,000.00
6Minnie MouseMr PeanutLooney Tunes Browdway 20041182024-202350,000.00
7Duffy DuckScooby DooLooney Tunes Browdway 20041182024-202350,000.00
8
9
10NamePeriodBooked Revenue
11Mickey Mouse2024100,000.00
12Minnie Mouse2024100,000.00
13Duffy Duck2024100,000.00
14Mr Peanut2024100,000.00
15Scooby Doo2024100,000.00
Revenue
Cell Formulas
RangeFormula
C11:C15C11=SUM(TAKE(UNIQUE(FILTER(D$2:G$7,((B$2:B$7=A11)+(A$2:A$7=A11))*(F$2:F$7=B11))),,-1))
amazing! thank you so much @Peter_SSs this is what I was looking for! I'll test it out with my full scenario but thats the correct total revenue!! 🙏
 
Upvote 0

Forum statistics

Threads
1,224,815
Messages
6,181,136
Members
453,021
Latest member
Justyna P

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