Index Match & sumifs question?

pierre robinson

New Member
Joined
Sep 28, 2016
Messages
26
Office Version
  1. 365
Platform
  1. Windows
So I have 2 sheets.

The first shows a UID, dates when payments were made against that UID & how much was paid.

The second contains the UID & when that UID was bought & sold.

So I want to sum those payments against the UID between the bought and sold dates, between specific date ranges.

Examples below:

Sheet A

Code Date paid Amt
AFTM900061 13/02/2018 380
AFTM900061 20/02/2018 380
AFTM900061 27/02/2018 380
AFTM900061 6/03/2018 380
AFTM900061 13/03/2018 380
AFTM900061 20/03/2018 380
AFTM900061 27/03/2018 380
AFTM900061 3/04/2018 385
AFTM900061 10/04/2018 385
AFTM900061 17/04/2018 385
AFTM900061 24/04/2018 385
AFTM900061 1/05/2018 385
AFTM900061 8/05/2018 385
AFTM900062 13/02/2018 380
AFTM900062 20/02/2018 380
AFTM900062 27/02/2018 380
AFTM900062 6/03/2018 80
AFTM900062 13/03/2018 380
AFTM900062 20/03/2018 380
AFTM900062 27/03/2018 380
AFTM900062 3/04/2018 385
AFTM900062 10/04/2018 385
AFTM900062 17/04/2018 385
AFTM900062 24/04/2018 385
AFTM900062 1/05/2018 385
AFTM900062 8/05/2018 385
AFTM900063 13/02/2018 380
AFTM900063 20/02/2018 380
AFTM900063 27/02/2018 380
AFTM900063 6/03/2018 380
AFTM900063 13/03/2018 380
AFTM900063 20/03/2018 380
AFTM900063 27/03/2018 380


[TABLE="width: 223"]
<colgroup><col><col><col></colgroup><tbody>[TR]
[TD]Sheet 2

[TABLE="width: 280"]
<colgroup><col><col><col></colgroup><tbody>[TR]
[TD]Code[/TD]
[TD] Acquisition Date[/TD]
[TD] Sale Date[/TD]
[/TR]
[TR]
[TD]PHSS016325[/TD]
[TD="align: right"]31/03/2016[/TD]
[TD] 17/10/2016[/TD]
[/TR]
[TR]
[TD]PHSS016518[/TD]
[TD="align: right"]31/03/2016[/TD]
[TD] 28/11/2016[/TD]
[/TR]
[TR]
[TD]PHSS016519[/TD]
[TD="align: right"]31/03/2016[/TD]
[TD] 28/11/2016[/TD]
[/TR]
[TR]
[TD]PHSS016326[/TD]
[TD="align: right"]31/03/2016[/TD]
[TD] 24/03/2017[/TD]
[/TR]
[TR]
[TD]ATUD900030[/TD]
[TD="align: right"]27/06/2017[/TD]
[TD] 23/05/2018[/TD]
[/TR]
[TR]
[TD]ATUD900031[/TD]
[TD="align: right"]27/06/2017[/TD]
[TD] 23/05/2018[/TD]
[/TR]
[TR]
[TD]ATUD900032[/TD]
[TD="align: right"]27/06/2017[/TD]
[TD] 23/05/2018[/TD]
[/TR]
[TR]
[TD]ATUD900033[/TD]
[TD="align: right"]27/06/2017[/TD]
[TD] 23/05/2018[/TD]
[/TR]
[TR]
[TD]AHSS900039[/TD]
[TD="align: right"]20/06/2017[/TD]
[TD] 23/05/2018[/TD]
[/TR]
[TR]
[TD]PFTS000064[/TD]
[TD="align: right"]31/03/2016[/TD]
[TD] 23/05/2018[/TD]
[/TR]
[TR]
[TD]PFTS000065[/TD]
[TD="align: right"]31/03/2016[/TD]
[TD] 23/05/2018[/TD]
[/TR]
[TR]
[TD]PFTS000066[/TD]
[TD="align: right"]31/03/2016[/TD]
[TD] 23/05/2018[/TD]
[/TR]
[TR]
[TD]PFTS000067[/TD]
[TD="align: right"]31/03/2016[/TD]
[TD] 23/05/2018[/TD]
[/TR]
[TR]
[TD]PFTS000068[/TD]
[TD="align: right"]31/03/2016[/TD]
[TD] 23/05/2018[/TD]
[/TR]
[TR]
[TD]PFTS000069[/TD]
[TD="align: right"]31/03/2016[/TD]
[TD] 23/05/2018[/TD]
[/TR]
[TR]
[TD]PHSS006008[/TD]
[TD="align: right"]31/03/2016[/TD]
[TD] 23/05/2018[/TD]
[/TR]
[TR]
[TD]PHSS006009[/TD]
[TD="align: right"]31/03/2016[/TD]
[TD] 23/05/2018[/TD]
[/TR]
[TR]
[TD]PHSS006590[/TD]
[TD="align: right"]31/03/2016[/TD]
[TD] 23/05/2018[/TD]
[/TR]
[TR]
[TD]PHSS007675[/TD]
[TD="align: right"]31/03/2016[/TD]
[TD] 23/05/2018[/TD]
[/TR]
[TR]
[TD]PHSM000402[/TD]
[TD="align: right"]31/03/2016[/TD]
[TD] 23/05/2018[/TD]
[/TR]
[TR]
[TD]PHSS007676[/TD]
[TD="align: right"]31/03/2016[/TD]
[TD] 23/05/2018[/TD]
[/TR]
[TR]
[TD]PHSS007677[/TD]
[TD="align: right"]31/03/2016 [/TD]
[TD]23/05/2018[/TD]
[/TR]
[TR]
[TD]PHSS007686[/TD]
[TD="align: right"]31/03/2016[/TD]
[TD] 23/05/2018[/TD]
[/TR]
[TR]
[TD]PHSM000403[/TD]
[TD="align: right"]31/03/2016[/TD]
[TD] 3/05/2018[/TD]
[/TR]
[TR]
[TD]PHSS008436[/TD]
[TD="align: right"]31/03/2016[/TD]
[TD] 23/05/2018[/TD]
[/TR]
[TR]
[TD]PHSS008876[/TD]
[TD="align: right"]31/03/2016 [/TD]
[TD]23/05/2018[/TD]
[/TR]
[TR]
[TD]PHSS008877[/TD]
[TD="align: right"]31/03/2016[/TD]
[TD] 23/05/2018[/TD]
[/TR]
[TR]
[TD]PHSS009586[/TD]
[TD="align: right"]31/03/2016[/TD]
[TD] 23/05/2018[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]


Solution

Code Date 1 Date 2 Date 3 Date 4 Date 5

Any brilliant ideas?

TIA
 

Excel Facts

Add Bullets to Range
Select range. Press Ctrl+1. On Number tab, choose Custom. Type Alt+7 then space then @ sign (using 7 on numeric keypad)

Forum statistics

Threads
1,223,908
Messages
6,175,307
Members
452,633
Latest member
DougMo

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