Need to sum multiple columns based on a date

gioprava

New Member
Joined
Apr 3, 2020
Messages
2
Office Version
  1. 2019
Platform
  1. Windows
Hi all, this is my first request post here, so let me know if I do something wrong and then I can improve...

My problem: I have a spreadsheet with a first column with the dates of the month, and I need to sum in a second column the costs I had for that same date on various marketing platforms.
Those costs are in the same spreadsheet, with different columns each: for each, I have the date and the cost associated with that date.
My issue is that I don't have always the costs, so sometimes it can be that I have just 5 days filled in for the whole month, while on some other column I'll have all the dates.

Here is an example:
DateTotal Daily CostsFacebook costs DateFacebook costsGoogle Ads DateGoogle Ads CostsBing DateBing Costs
01-03-202001-03-2020235€01-03-202015€01-03-202020€
02-03-202002-03-2020150€02-03-202035€05-03-202070€
03-03-202003-03-2020175€04-03-202045€
04-03-202004-03-202045€05-03-202070€
05-03-202005-03-2020110€

As you can see I can't sum just the columns based on the position of the first date, but I need a way to identify the A2 date in columns C, E and G and then sum the associated cost.
I checked around how to do that with SUMIF and MATCH and INDEX, but couldn't find a way to do that.

Thanks a lot!!
Giovanni
 

Excel Facts

Did you know Excel offers Filter by Selection?
Add the AutoFilter icon to the Quick Access Toolbar. Select a cell containing Apple, click AutoFilter, and you will get all rows with Apple
Try
Book1
ABCDEFGH
1DateTotal Daily CostsFacebook costs DateFacebook costsGoogle Ads DateGoogle Ads CostsBing DateBing Costs
21/3/20202701/3/2020235 €1/3/202015 €1/3/202020 €
32/3/20201852/3/2020150 €2/3/202035 €5/3/202070 €
43/3/20201753/3/2020175 €4/3/202045 €
54/3/2020904/3/202045 €5/3/202070 €
65/3/20202505/3/2020110 €
Sheet1 (2)
Cell Formulas
RangeFormula
B2:B6B2=SUMPRODUCT(((A2=$C$2:$C$6)*$D$2:$D$6)+(($E$2:$E$6=A2)*$F$2:$F$6)+(($G$2:$G$6=A2)*$H$2:$H$6))
 
Upvote 0

Forum statistics

Threads
1,213,544
Messages
6,114,239
Members
448,555
Latest member
RobertJones1986

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