Is there a function for this?

G

Guest

code value A value B value C value D test
1 5,000 250 5,000 0
1 10,000 250 500 9,250
2 20,000 5,000 500 14,500
3 5,000 500 600 5,000 0
3 10,000 7,000 800 2,200
3 20,000 30,000 0
Total test 25,950

1 9,250
2 14,500
3 2,200
Total test 25,950


The "test" field contains =MAX(0,B2-C2-D2-E2) Is there a function that will
sum that formula by the "code" field without using the "test" field?
 
D

daddylonglegs

Perhaps this

=SUMPRODUCT(--(A2:A7=1),--(B2:B7-C2:C7-D2:D7-E2:E7>0),B2:B7-C2:C7-D2:D7-E2:E7)
 
G

Guest

Very cool daddy!

I use similar sumproduct configurations but couldn't figure this one out.

Thanks.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top