Help with Combination of VLookUp and SumIfs

massig

New Member
Joined
Aug 1, 2019
Messages
7
Office Version
  1. 2021
Hi have 2 sheets


I am trying to find with the sumifs and sum all the number of touches that match the company name ... but i also want to add a second constraint - which is only sum if the touches are Before the date of the opportunity. I tried to put x lookup twice - but somehow it does not work...

I wonder if anyone can help refining the formula (if there is a formula that can actually do this at all!)

Or MInisheet 1

helpforsumif.xlsx
ABCD
1COMPANYOPPORTUNITYCREATED DATENUMBER OF TOUCHES
2ABCLaptops01/12/2022no match
3DEFServers01/01/20238
4GHIServers01/03/2023no match
5SLMSoftware01/05/2023no match
OPPS
Cell Formulas
RangeFormula
D2,D4:D5D2=XLOOKUP(A:A,'PIVOT FOR SUMIFS'!A:A,'PIVOT FOR SUMIFS'!C:C,"no match",FALSE)
D3D3=SUMIFS('PIVOT FOR SUMIFS'!C:C,'PIVOT FOR SUMIFS'!A:A,XLOOKUP(A:A,'PIVOT FOR SUMIFS'!A:A,'PIVOT FOR SUMIFS'!A:A,"no match",FALSE))


MINISHEET 2
helpforsumif.xlsx
ABC
1COMPANYTouch DATETOUCHES
2DEF01/12/20222
3DEF23/12/20223
4DEF04/03/20233
PIVOT FOR SUMIFS
 

Excel Facts

Shade all formula cells
To shade all formula cells: Home, Find & Select, Formulas to select all formulas. Then apply a light fill color.
What version of Excel are you using?

I suggest that you update your Account details (or click your user name at the top right of the forum) so helpers always know what Excel version(s) & platform(s) you are using as the best solution often varies by version. (Don’t forget to scroll down & ‘Save’)
 
Upvote 0
How about
Excel Formula:
=SUMIFS('PIVOT FOR SUMIFS'!C:C,'PIVOT FOR SUMIFS'!A:A,A2,'PIVOT FOR SUMIFS'!B:B,"<="&C2)
 
Upvote 0
What version of Excel are you using?

I suggest that you update your Account details (or click your user name at the top right of the forum) so helpers always know what Excel version(s) & platform(s) you are using as the best solution often varies by version. (Don’t forget to scroll down & ‘Save’)
HI - thank you - I have updated it - I am using Office 2021
 
Upvote 0
Cross-posting (posting the same question in more than one forum) is not against our rules, but the method of doing so is covered by #13 of the Forum Rules.

Be sure to follow & read the link at the end of the rule too!

Cross posted at: Help with Combination of VLookUp and SumIfs
There is no need to repeat the link(s) provided above but if you have posted the question at other places, please provide links to those as well.

If you do cross-post in the future and also provide links, then there shouldn’t be a problem.
 
Upvote 0
I works for me
helpforsumif.xlsx
ABCE
1COMPANYOPPORTUNITYCREATED DATE
2ABCLaptops01/12/20220
3DEFServers01/01/20235
4GHIServers01/03/20230
5SLMSoftware01/05/20230
OPPS
Cell Formulas
RangeFormula
E2:E5E2=SUMIFS('PIVOT FOR SUMIFS'!C:C,'PIVOT FOR SUMIFS'!A:A,A2,'PIVOT FOR SUMIFS'!B:B,"<="&C2)
 
Upvote 0
Solution
I used the formula =SUMIFS('PIVOT FOR SUMIFS'!C:C,'PIVOT FOR SUMIFS'!A:A,A3,'PIVOT FOR SUMIFS'!B:B,"<="&C3) and that worked Thank you!
 
Upvote 0
Glad to help & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,181
Members
453,022
Latest member
Mohamed Magdi Tawfiq Emam

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