PDA

View Full Version : Solved: Help: how to re-use Database function with fixed criteria header



yurble_vn
12-09-2007, 03:47 AM
Hi All,

I looking for a way to use database function in following way, please help:
Criteria1 -- Criteria2 --Criteria3
C1-i--------- C2-i --------C3-i --------DB function
C1-ii---------C2-ii---------C3-ii--------DB function
C1-iii---------C2-iii--------C3-iii--------DB function
C1-iv---------C2-iv-------C3-iv--------DB function
C1-v----------C2-v-------C3-v---------DB function

What I trying to do is:

with each function in the right side will use the criteria in the left. And they all use the same criteria header (the red text)

Please help

Bob Phillips
12-09-2007, 05:21 AM
That makes no sense to me. Post data with expected results, not some schema.

yurble_vn
12-09-2007, 06:02 AM
Here it comes

Thanks for prompt feedback..

Bob Phillips
12-09-2007, 06:21 AM
How aboutt using a diufferent formula

=SUMPRODUCT(--(INDEX(AllData,,1)=$A3),--(INDEX(AllData,,2)=$B3),--(INDEX(AllData,,3)=$C3),INDEX(AllData,,COLUMN()+2))

yurble_vn
12-09-2007, 06:26 AM
FYI, I currently use sumproduct to sum multi criteria.
But for big data, sumproduct seems to be a disadvantage.

That why I try to look for some other way by Database function.

But, criteria header is the only barrier

Bob Phillips
12-09-2007, 06:34 AM
It is, but do you want results or not?

You could also make the dynamic range mmore specific so that SP works on less cells.

yurble_vn
12-09-2007, 06:49 AM
Thanks XLD,

Could you please give more details explaination.... ? I not very expert in excel.

Bob Phillips
12-09-2007, 06:56 AM
I've thought of a DSUM way

=DSUM(AllData,F$2,$A$2:$C3)-SUM(F$2:F2)

yurble_vn
12-09-2007, 07:18 AM
Oops

That's really a simple brillant solution.

Many thanks XLD

Bob Phillips
12-09-2007, 08:18 AM
And it is 4.5 times quicker.