Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
towl
 
Posts: n/a
Default Sum If or DSUM help?


Hi, I have a table full of data, and I want to do a sum on the data, if
two conditions are met, for example:

3 Columns A , B, C contain:
In A Sex
In B Age
In C Salary

Down the rows it is Male or Female persons age and Salary.


I then have another table with criteria in it, again 3 columns ABC
A Sex
B Age
C hopeful formula result

In c I am after the sum of all the salaries of the two conditions in
A&B, so if A is male and B is 24, I want the formula to sum up all the
salaries of Male 24 year olds in the origional table.

I know this could be done in lotus, but can it be done in Excel?

Any help appreciated.


--
towl
------------------------------------------------------------------------
towl's Profile: http://www.excelforum.com/member.php...o&userid=26340
View this thread: http://www.excelforum.com/showthread...hreadid=396082

  #2   Report Post  
Bob Phillips
 
Posts: n/a
Default

=sumproduct(--(A2:A200=sex),--(B2:B200=age),C2:C200)

--
HTH

Bob Phillips

"towl" wrote in message
...

Hi, I have a table full of data, and I want to do a sum on the data, if
two conditions are met, for example:

3 Columns A , B, C contain:
In A Sex
In B Age
In C Salary

Down the rows it is Male or Female persons age and Salary.


I then have another table with criteria in it, again 3 columns ABC
A Sex
B Age
C hopeful formula result

In c I am after the sum of all the salaries of the two conditions in
A&B, so if A is male and B is 24, I want the formula to sum up all the
salaries of Male 24 year olds in the origional table.

I know this could be done in lotus, but can it be done in Excel?

Any help appreciated.


--
towl
------------------------------------------------------------------------
towl's Profile:

http://www.excelforum.com/member.php...o&userid=26340
View this thread: http://www.excelforum.com/showthread...hreadid=396082



  #3   Report Post  
Devlin
 
Posts: n/a
Default

You can make another column (let's say D) near the original table where
you will put the concatenated values of SEX and AGE cells: =A2&B2 ---
so you'll have something like Male24. Then, in the second table you'll
use sumif - for instance, supposing that he columns of your second
table are M=SEX, N=AGE, O=formula you want, then the formula will be
=sumif(D2:D100,M2&N2,C2:C100). Excel will search column D for all the
Male24 and will sum the corresponding values from column C.

Best luck,
Devlin

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
dsum PaulOakley New Users to Excel 1 July 18th 05 04:49 PM
conditional criteria in DSUM S. H. Drew Excel Discussion (Misc queries) 7 May 2nd 05 06:14 PM
DSUM and DCount when criteria values are similar BAC Excel Worksheet Functions 1 February 14th 05 06:38 PM
Use of the DSUM formula to find exact matches in datatables Rob Henson Excel Worksheet Functions 1 January 27th 05 02:14 AM
DSUM frustrations Paul Adams Excel Worksheet Functions 0 November 12th 04 10:56 AM


All times are GMT +1. The time now is 05:23 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"