Sumproduct problem

User3340

New Member
Joined
Apr 12, 2007
Messages
46
I am trying to use sumproduct to count the number of times a certain combination of database entries come up. Specifically, I want to count an entry if it has a certain date, then match that up with a client. Clients can have more than one entry per date, and I want to be able to keep a running total of how many entries they have per date. Am I using the wrong formula?
 

Excel Facts

Whats the difference between CONCAT and CONCATENATE?
The newer CONCAT function can reference a range of cells. =CONCATENATE(A1,A2,A3,A4,A5) becomes =CONCAT(A1:A5)
No your using the right formula

Can you post some data and actual formulas please
 
Upvote 0
I am trying to use sumproduct to count the number of times a certain combination of database entries come up. Specifically, I want to count an entry if it has a certain date, then match that up with a client. Clients can have more than one entry per date, and I want to be able to keep a running total of how many entries they have per date. Am I using the wrong formula?

=SUMPRODUCT(--(DateRange=Date),--(ClientRange=Client))

Date and Clients are cell references that house conditions which the relevant ranges must meet.
 
Upvote 0
further sumproduct...

Here is the formula I am trying to use:
=SUMPRODUCT((A9='Hedge Records'!$B$2:$B$3)*('FX Data Sheet'!$E$5='Hedge Records'!$A$2:$A$3)*('Hedge Records'!$I$2:$I$3))

The above formula actually works, as the "Hedge Records" sheet only has two entries (in row 2 and 3). When I try to extend the array (eg from B3 to B1000, so I don't have to think about updating it), I get a #value error.

In the formula, A9 is a client's name and E5 is a date.
 
Upvote 0
Re: further sumproduct...

Here is the formula I am trying to use:
=SUMPRODUCT((A9='Hedge Records'!$B$2:$B$3)*('FX Data Sheet'!$E$5='Hedge Records'!$A$2:$A$3)*('Hedge Records'!$I$2:$I$3))

The above formula actually works, as the "Hedge Records" sheet only has two entries (in row 2 and 3). When I try to extend the array (eg from B3 to B1000, so I don't have to think about updating it), I get a #value error.

In the formula, A9 is a client's name and E5 is a date.

=SUMPRODUCT(--(A9='Hedge Records'!$B$2:$B$3),--('FX Data Sheet'!$E$5='Hedge Records'!$A$2:$A$3),Hedge Records'!$I$2:$I$3)
 
Upvote 0
Still not working

That still returns #vale error when I change it to include a larger array than is listed. I want to be able to include an enormous array that will be filled as entries are posted. Please help.
 
Upvote 0
Re: Still not working

That still returns #vale error when I change it to include a larger array than is listed. I want to be able to include an enormous array that will be filled as entries are posted. Please help.

You can't use whole columns like B:B, unless on Excel 2007...

You can't get #VALUE! error, unless the relevant ranges themselves house such an error.
 
Upvote 0

Forum statistics

Threads
1,214,978
Messages
6,122,545
Members
449,089
Latest member
davidcom

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