Multiply a string of cells per the criteria

Grexx

New Member
Joined
Aug 16, 2017
Messages
1
HI, I hope I formulated the topic correctly. What I want to do is to multiply Rooms by ADR for each date and sum them together to get total revenue for all days in a given segment (for example in row 5 and the result will be in cell S5). I thought of going with SUMPRODUCT but cannot figure out how. Can you please help? Thank you.


[TABLE="width: 1216"]
<tbody>[TR]
[TD][/TD]
[TD]A[/TD]
[TD]B[/TD]
[TD]C[/TD]
[TD]D[/TD]
[TD]E[/TD]
[TD]F[/TD]
[TD]G[/TD]
[TD]H[/TD]
[TD]I[/TD]
[TD]J[/TD]
[TD]K[/TD]
[TD]L[/TD]
[TD]M[/TD]
[TD]N[/TD]
[TD]O[/TD]
[TD]P[/TD]
[TD]Q[/TD]
[TD]R[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD][/TD]
[TD][/TD]
[TD]7-Aug[/TD]
[TD]7-Aug[/TD]
[TD]8-Aug[/TD]
[TD]8-Aug[/TD]
[TD]9-Aug[/TD]
[TD]9-Aug[/TD]
[TD]10-Aug[/TD]
[TD]10-Aug[/TD]
[TD]11-Aug[/TD]
[TD]11-Aug[/TD]
[TD]12-Aug[/TD]
[TD]12-Aug[/TD]
[TD]13-Aug[/TD]
[TD]13-Aug[/TD]
[TD]Totals[/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]2[/TD]
[TD][/TD]
[TD][/TD]
[TD]Monday[/TD]
[TD]Monday[/TD]
[TD]Tuesday[/TD]
[TD]Tuesday[/TD]
[TD]Wednesday[/TD]
[TD]Wednesday[/TD]
[TD]Thursday[/TD]
[TD]Thursday[/TD]
[TD]Friday[/TD]
[TD]Friday[/TD]
[TD]Saturday[/TD]
[TD]Saturday[/TD]
[TD]Sunday[/TD]
[TD]Sunday[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]3[/TD]
[TD][/TD]
[TD][/TD]
[TD]Rooms[/TD]
[TD]ADR[/TD]
[TD]Rooms[/TD]
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D]$19.77[/TD]
[TD]18[/TD]
[TD]$14.87[/TD]
[TD]20[/TD]
[TD]$9.47[/TD]
[TD]18[/TD]
[TD]$16.75[/TD]
[TD]13[/TD]
[TD]$11.34[/TD]
[TD]9[/TD]
[TD]$14.09[/TD]
[TD]9[/TD]
[TD]$18.03[/TD]
[TD]108[/TD]
[TD]21%[/TD]
[TD] $ 10.74[/TD]
[/TR]
[TR]
[TD]8[/TD]
[TD][/TD]
[TD]D1[/TD]
[TD]34[/TD]
[TD]$106.71[/TD]
[TD]32[/TD]
[TD]$110.47[/TD]
[TD]33[/TD]
[TD]$109.77[/TD]
[TD]37[/TD]
[TD]$111.28[/TD]
[TD]51[/TD]
[TD]$135.27[/TD]
[TD]53[/TD]
[TD]$138.06[/TD]
[TD]30[/TD]
[TD]$126.01[/TD]
[TD]270[/TD]
[TD]52.22%[/TD]
[TD] $ 121.85[/TD]
[/TR]
[TR]
[TD]9[/TD]
[TD][/TD]
[TD]D2[/TD]
[TD]13[/TD]
[TD]$86.94[/TD]
[TD]14[/TD]
[TD]$95.60[/TD]
[TD]13[/TD]
[TD]$100.30[/TD]
[TD]19[/TD]
[TD]$94.53[/TD]
[TD]38[/TD]
[TD]$123.93[/TD]
[TD]44[/TD]
[TD]$123.97[/TD]
[TD]21[/TD]
[TD]$107.98[/TD]
[TD]162[/TD]
[TD]45.25%[/TD]
[TD] $ 111.11[/TD]
[/TR]
[TR]
[TD]10[/TD]
[TD]Other Discounts[/TD]
[TD]var[/TD]
[TD]5[/TD]
[TD]-$18.05[/TD]
[TD]5[/TD]
[TD]-$16.43[/TD]
[TD]5[/TD]
[TD]$22.48[/TD]
[TD]8[/TD]
[TD]$32.87[/TD]
[TD]0[/TD]
[TD]$38.53[/TD]
[TD]-5[/TD]
[TD]$26.76[/TD]
[TD]0[/TD]
[TD]$12.85[/TD]
[TD]18[/TD]
[TD]3%[/TD]
[TD] $ 16.40[/TD]
[/TR]
[TR]
[TD]11[/TD]
[TD][/TD]
[TD]D1[/TD]
[TD]25[/TD]
[TD]$128.27[/TD]
[TD]17[/TD]
[TD]$140.33[/TD]
[TD]17[/TD]
[TD]$150.72[/TD]
[TD]21[/TD]
[TD]$150.07[/TD]
[TD]31[/TD]
[TD]$160.05[/TD]
[TD]34[/TD]
[TD]$166.58[/TD]
[TD]23[/TD]
[TD]$132.97[/TD]
[TD]168[/TD]
[TD]32.50%[/TD]
[TD] $ 148.75[/TD]
[/TR]
[TR]
[TD]12[/TD]
[TD][/TD]
[TD]D2[/TD]
[TD]20[/TD]
[TD]$146.32[/TD]
[TD]12[/TD]
[TD]$156.76[/TD]
[TD]12[/TD]
[TD]$128.24[/TD]
[TD]13[/TD]
[TD]$117.20[/TD]
[TD]31[/TD]
[TD]$121.52[/TD]
[TD]39[/TD]
[TD]$139.82[/TD]
[TD]23[/TD]
[TD]$120.12[/TD]
[TD]150[/TD]
[TD]41.90%[/TD]
[TD] $ 132.35[/TD]
[/TR]
[TR]
[TD]13[/TD]
[TD]Rack, Internet, Discounts Totals[/TD]
[TD]var[/TD]
[TD]25[/TD]
[TD]-$4.61[/TD]
[TD]23[/TD]
[TD]-$0.59[/TD]
[TD]31[/TD]
[TD]$12.19[/TD]
[TD]29[/TD]
[TD]$23.55[/TD]
[TD]16[/TD]
[TD]$24.39[/TD]
[TD]7[/TD]
[TD]$16.90[/TD]
[TD]10[/TD]
[TD]$12.05[/TD]
[TD]141[/TD]
[TD]27%[/TD]
[TD] $ 11.72[/TD]
[/TR]
[TR]
[TD]14[/TD]
[TD][/TD]
[TD]D1[/TD]
[TD]63[/TD]
[TD]$115.97[/TD]
[TD]53[/TD]
[TD]$120.61[/TD]
[TD]57[/TD]
[TD]$124.97[/TD]
[TD]65[/TD]
[TD]$127.38[/TD]
[TD]87[/TD]
[TD]$146.43[/TD]
[TD]92[/TD]
[TD]$149.13[/TD]
[TD]57[/TD]
[TD]$129.93[/TD]
[TD]474[/TD]
[TD]91.68%[/TD]
[TD] $ 132.84[/TD]
[/TR]
[TR]
[TD]15[/TD]
[TD][/TD]
[TD]D2[/TD]
[TD]38[/TD]
[TD]$120.58[/TD]
[TD]30[/TD]
[TD]$121.20[/TD]
[TD]26[/TD]
[TD]$112.78[/TD]
[TD]36[/TD]
[TD]$103.84[/TD]
[TD]71[/TD]
[TD]$122.04[/TD]
[TD]85[/TD]
[TD]$132.23[/TD]
[TD]47[/TD]
[TD]$117.88[/TD]
[TD]333[/TD]
[TD]93.02%[/TD]
[TD] $ 121.12[/TD]
[/TR]
</tbody>[/TABLE]

[TABLE="width: 1263"]
<tbody>[TR]
[TD="colspan: 2"][/TD]
[TD="colspan: 2"][/TD]
[TD="colspan: 2"][/TD]
[TD="colspan: 2"][/TD]
[TD="colspan: 2"][/TD]
[TD="colspan: 2"][/TD]
[TD="colspan: 2"][/TD]
[TD="colspan: 3"][/TD]
[/TR]
[TR]
[TD="colspan: 2"][/TD]
[/TR]
</tbody>[/TABLE]
 

Excel Facts

Formula for Yesterday
Name Manager, New Name. Yesterday =TODAY()-1. OK. Then, use =YESTERDAY in any cell. Tomorrow could be =TODAY()+1.
HI, I hope I formulated the topic correctly. What I want to do is to multiply Rooms by ADR for each date and sum them together to get total revenue for all days in a given segment (for example in row 5 and the result will be in cell S5). I thought of going with SUMPRODUCT but cannot figure out how. Can you please help? Thank you.


[TABLE="width: 1216"]
<tbody>[TR]
[TD][/TD]
[TD]A[/TD]
[TD]B[/TD]
[TD]C[/TD]
[TD]D[/TD]
[TD]E[/TD]
[TD]F[/TD]
[TD]G[/TD]
[TD]H[/TD]
[TD]I[/TD]
[TD]J[/TD]
[TD]K[/TD]
[TD]L[/TD]
[TD]M[/TD]
[TD]N[/TD]
[TD]O[/TD]
[TD]P[/TD]
[TD]Q[/TD]
[TD]R[/TD]
[TD]S[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD][/TD]
[TD][/TD]
[TD]7-Aug[/TD]
[TD]7-Aug[/TD]
[TD]8-Aug[/TD]
[TD]8-Aug[/TD]
[TD]9-Aug[/TD]
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TD]
[TD]4[/TD]
[TD]$117.86[/TD]
[TD]7[/TD]
[TD]$134.06[/TD]
[TD]7[/TD]
[TD]$144.43[/TD]
[TD]5[/TD]
[TD]$175.84[/TD]
[TD]5[/TD]
[TD]$147.84[/TD]
[TD]4[/TD]
[TD]$141.91[/TD]
[TD]36[/TD]
[TD]6.96%[/TD]
[TD] $ -[/TD]
[/TR]
[TR]
[TD]6[/TD]
[TD][/TD]
[TD]D2[/TD]
[TD]5[/TD]
[TD]$105.08[/TD]
[TD]4[/TD]
[TD]$104.10[/TD]
[TD]1[/TD]
[TD]$89.38[/TD]
[TD]4[/TD]
[TD]$104.60[/TD]
[TD]2[/TD]
[TD]$94.29[/TD]
[TD]2[/TD]
[TD]$166.10[/TD]
[TD]3[/TD]
[TD]$170.07[/TD]
[TD]21[/TD]
[TD]5.87%[/TD]
[TD] $ 118.12[/TD]
[/TR]
[TR]
[TD]7[/TD]
[TD]Internet[/TD]
[TD]var[/TD]
[TD]21[/TD]
[TD]$19.77[/TD]
[TD]18[/TD]
[TD]$14.87[/TD]
[TD]20[/TD]
[TD]$9.47[/TD]
[TD]18[/TD]
[TD]$16.75[/TD]
[TD]13[/TD]
[TD]$11.34[/TD]
[TD]9[/TD]
[TD]$14.09[/TD]
[TD]9[/TD]
[TD]$18.03[/TD]
[TD]108[/TD]
[TD]21%[/TD]
[TD] $ 10.74[/TD]
[/TR]
[TR]
[TD]8[/TD]
[TD][/TD]
[TD]D1[/TD]
[TD]34[/TD]
[TD]$106.71[/TD]
[TD]32[/TD]
[TD]$110.47[/TD]
[TD]33[/TD]
[TD]$109.77[/TD]
[TD]37[/TD]
[TD]$111.28[/TD]
[TD]51[/TD]
[TD]$135.27[/TD]
[TD]53[/TD]
[TD]$138.06[/TD]
[TD]30[/TD]
[TD]$126.01[/TD]
[TD]270[/TD]
[TD]52.22%[/TD]
[TD] $ 121.85[/TD]
[/TR]
[TR]
[TD]9[/TD]
[TD][/TD]
[TD]D2[/TD]
[TD]13[/TD]
[TD]$86.94[/TD]
[TD]14[/TD]
[TD]$95.60[/TD]
[TD]13[/TD]
[TD]$100.30[/TD]
[TD]19[/TD]
[TD]$94.53[/TD]
[TD]38[/TD]
[TD]$123.93[/TD]
[TD]44[/TD]
[TD]$123.97[/TD]
[TD]21[/TD]
[TD]$107.98[/TD]
[TD]162[/TD]
[TD]45.25%[/TD]
[TD] $ 111.11[/TD]
[/TR]
[TR]
[TD]10[/TD]
[TD]Other Discounts[/TD]
[TD]var[/TD]
[TD]5[/TD]
[TD]-$18.05[/TD]
[TD]5[/TD]
[TD]-$16.43[/TD]
[TD]5[/TD]
[TD]$22.48[/TD]
[TD]8[/TD]
[TD]$32.87[/TD]
[TD]0[/TD]
[TD]$38.53[/TD]
[TD]-5[/TD]
[TD]$26.76[/TD]
[TD]0[/TD]
[TD]$12.85[/TD]
[TD]18[/TD]
[TD]3%[/TD]
[TD] $ 16.40[/TD]
[/TR]
[TR]
[TD]11[/TD]
[TD][/TD]
[TD]D1[/TD]
[TD]25[/TD]
[TD]$128.27[/TD]
[TD]17[/TD]
[TD]$140.33[/TD]
[TD]17[/TD]
[TD]$150.72[/TD]
[TD]21[/TD]
[TD]$150.07[/TD]
[TD]31[/TD]
[TD]$160.05[/TD]
[TD]34[/TD]
[TD]$166.58[/TD]
[TD]23[/TD]
[TD]$132.97[/TD]
[TD]168[/TD]
[TD]32.50%[/TD]
[TD] $ 148.75[/TD]
[/TR]
[TR]
[TD]12[/TD]
[TD][/TD]
[TD]D2[/TD]
[TD]20[/TD]
[TD]$146.32[/TD]
[TD]12[/TD]
[TD]$156.76[/TD]
[TD]12[/TD]
[TD]$128.24[/TD]
[TD]13[/TD]
[TD]$117.20[/TD]
[TD]31[/TD]
[TD]$121.52[/TD]
[TD]39[/TD]
[TD]$139.82[/TD]
[TD]23[/TD]
[TD]$120.12[/TD]
[TD]150[/TD]
[TD]41.90%[/TD]
[TD] $ 132.35[/TD]
[/TR]
[TR]
[TD]13[/TD]
[TD]Rack, Internet, Discounts Totals[/TD]
[TD]var[/TD]
[TD]25[/TD]
[TD]-$4.61[/TD]
[TD]23[/TD]
[TD]-$0.59[/TD]
[TD]31[/TD]
[TD]$12.19[/TD]
[TD]29[/TD]
[TD]$23.55[/TD]
[TD]16[/TD]
[TD]$24.39[/TD]
[TD]7[/TD]
[TD]$16.90[/TD]
[TD]10[/TD]
[TD]$12.05[/TD]
[TD]141[/TD]
[TD]27%[/TD]
[TD] $ 11.72[/TD]
[/TR]
[TR]
[TD]14[/TD]
[TD][/TD]
[TD]D1[/TD]
[TD]63[/TD]
[TD]$115.97[/TD]
[TD]53[/TD]
[TD]$120.61[/TD]
[TD]57[/TD]
[TD]$124.97[/TD]
[TD]65[/TD]
[TD]$127.38[/TD]
[TD]87[/TD]
[TD]$146.43[/TD]
[TD]92[/TD]
[TD]$149.13[/TD]
[TD]57[/TD]
[TD]$129.93[/TD]
[TD]474[/TD]
[TD]91.68%[/TD]
[TD] $ 132.84[/TD]
[/TR]
[TR]
[TD]15[/TD]
[TD][/TD]
[TD]D2[/TD]
[TD]38[/TD]
[TD]$120.58[/TD]
[TD]30[/TD]
[TD]$121.20[/TD]
[TD]26[/TD]
[TD]$112.78[/TD]
[TD]36[/TD]
[TD]$103.84[/TD]
[TD]71[/TD]
[TD]$122.04[/TD]
[TD]85[/TD]
[TD]$132.23[/TD]
[TD]47[/TD]
[TD]$117.88[/TD]
[TD]333[/TD]
[TD]93.02%[/TD]
[TD] $ 121.12[/TD]
[/TR]
</tbody>[/TABLE]

[TABLE="width: 1263"]
<tbody>[TR]
[TD="colspan: 2"][/TD]
[TD="colspan: 2"][/TD]
[TD="colspan: 2"][/TD]
[TD="colspan: 2"][/TD]
[TD="colspan: 2"][/TD]
[TD="colspan: 2"][/TD]
[TD="colspan: 2"][/TD]
[TD="colspan: 3"][/TD]
[/TR]
[TR]
[TD="colspan: 2"][/TD]
[/TR]
</tbody>[/TABLE]

S4=SUM(IF($C$3:$O$3="Rooms",$C4:$O4*$D4:$P4,0)) press CTRL+SHIFT+ENTER
 
Upvote 0

Forum statistics

Threads
1,223,903
Messages
6,175,289
Members
452,631
Latest member
a_potato

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