Identify credits and debits within a week of each other

simonpp

New Member
Joined
Aug 27, 2009
Messages
2
Hi,

I have a worksheet with multiple bank statement all combined together and sorted by date.
Column E has the date, Column H has Debits and Column I has Credits, Row 1 has headers.

I am trying to find a way of identifying debits and credits within a week of each other where the amount is the same. E.g. where a £1,234 credit (in column I) correlates with a £1,234 debit in the week before or after (in column H). I am trying to eliminate matches where

The bit I'm struggling with is accurately searching within a week of the date of the credit to find matching debits.

=IF(COUNTIF(H:H,I4)>0,"Found","Not Found") finds matches but within the whole range.

This is what I've been playing around with although unreliably.
=IF(SUMPRODUCT(--(ABS(E$2:E$14031-E2)>=7),--(H$2:H$14031=I2))>1,"Yes","No")

If it makes any difference I'm using Excel 2003. :eek:
 

Excel Facts

What did Pito Salas invent?
Pito Salas, working for Lotus, popularized what would become to be pivot tables. It was released as Lotus Improv in 1989.
This formula might work:
Code:
=IF(H2>0,SUMPRODUCT(--(E2<$E$2:$E$199+7),--(E2>$E$2:$E$199-7),--(H2=$I$2:$I$199)),"")

You would probably also want another column with the above formula changed to IF(I2>0 .....
 
Upvote 0

Forum statistics

Threads
1,215,688
Messages
6,126,210
Members
449,299
Latest member
KatieTrev

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