close

I have been trying to figure out how to create a formula in Excel 2003 that
will sum only if 2 variables are met. An example would be if you had 5000
rows of data. Columns are NAME, AGE, CITY. Let's say I wanted to sum how
many people are in Seattle and are 25 can Excel do this?

One way ..

Assuming City in col C, Age in col B
data from row2 to 5000

we could put in say E1:
=SUMPRODUCT(($C$2:$C$5000=quot;Seattlequot;)*($B$2:$B$5000 =25))

Alternatively,
we could point to cells instead of hardcoding
so if we input in D1: Seattle, in D2: 25,
then in E1:
=SUMPRODUCT(($C$2:$C$5000=D1)*($B$2:$B$5000=D2))
--
Max
Singapore
savefile.com/projects/236895
xdemechanik
---
quot;B Akersquot; lt;B gt; wrote in message
...
gt; I have been trying to figure out how to create a formula in Excel 2003
that
gt; will sum only if 2 variables are met. An example would be if you had 5000
gt; rows of data. Columns are NAME, AGE, CITY. Let's say I wanted to sum how
gt; many people are in Seattle and are 25 can Excel do this?
Use function. DSUM--
M.A.
quot;B Akersquot; lt;B gt; wrote in message ...
gt;I have been trying to figure out how to create a formula in Excel 2003 that
gt; will sum only if 2 variables are met. An example would be if you had 5000
gt; rows of data. Columns are NAME, AGE, CITY. Let's say I wanted to sum how
gt; many people are in Seattle and are 25 can Excel do this?

arrow
arrow
    全站熱搜
    創作者介紹
    創作者 software 的頭像
    software

    software

    software 發表在 痞客邦 留言(0) 人氣()