#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
TC TC is offline
external usenet poster
 
Posts: 32
Default COUNT

Hi, I am using Microsoft 2003. I am trying to add the amount of X's in my
excel and seperate them by the YEAR/WK.

For example I want to know how many X's I have for 200948. For this
function I dont care about the column they are in just how many X's there
are. My sheet is much larger than the one below but it is a sample. I
understand I will have to have a new function per pln_s_yrwk. Any help
would be great!!



yrwk SOC OPC PUR M. PLN
D. PLN
200948 0 0 0 x 0
200951 0 x 0 0 0
200948 0 0 0 x x
200947 0 0 x 0 0
200946 0 0 0 0 x

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 35,218
Default COUNT

=SUMPRODUCT((A1:A5=200948)*(B1:F5="x"))

Adjust the ranges to match--but you can't use whole columns (except in xl2007+).

Bob Phillips explains =sumproduct() in much more detail he
http://www.xldynamic.com/source/xld.SUMPRODUCT.html


TC wrote:

Hi, I am using Microsoft 2003. I am trying to add the amount of X's in my
excel and seperate them by the YEAR/WK.

For example I want to know how many X's I have for 200948. For this
function I dont care about the column they are in just how many X's there
are. My sheet is much larger than the one below but it is a sample. I
understand I will have to have a new function per pln_s_yrwk. Any help
would be great!!

yrwk SOC OPC PUR M. PLN
D. PLN
200948 0 0 0 x 0
200951 0 x 0 0 0
200948 0 0 0 x x
200947 0 0 x 0 0
200946 0 0 0 0 x


--

Dave Peterson
  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 11,501
Default COUNT

Hi,

This assumes your data are in columns A through E

=SUMPRODUCT((A1:A10=200948)*(B1:E10="x"))

Mike

"TC" wrote:

Hi, I am using Microsoft 2003. I am trying to add the amount of X's in my
excel and seperate them by the YEAR/WK.

For example I want to know how many X's I have for 200948. For this
function I dont care about the column they are in just how many X's there
are. My sheet is much larger than the one below but it is a sample. I
understand I will have to have a new function per pln_s_yrwk. Any help
would be great!!



yrwk SOC OPC PUR M. PLN
D. PLN
200948 0 0 0 x 0
200951 0 x 0 0 0
200948 0 0 0 x x
200947 0 0 x 0 0
200946 0 0 0 0 x

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 905
Default COUNT

"TC" wrote:
Hi, I am using Microsoft 2003. I am trying to add the amount of X's
in my excel and seperate them by the YEAR/WK.
For example I want to know how many X's I have for 200948. For
this function I dont care about the column they are in just how many
X's there are.


Kudos for providing a concise example. But it would have been helpful if
you told us Xs you would count for 200948: 3 (all Xs), or just 2 (number of
rows with one or more Xs).

As clear as you might think your description is, you'd be surprised how many
times people describe their requirements clearly incorrectly ;-).

If you would count 3 Xs for 200948, then:

=SUMPRODUCT((B2:F5="x")*(A2:A5=200948))

If you would count 2 Xs for 200948, then:

=SUMPRODUCT(--(COUNTIF(INDIRECT("B"&ROW(2:6)&":F"&ROW(2:6)),"x") 0) *
(A2:A6=200948))


----- original message -----

"TC" wrote in message
...
Hi, I am using Microsoft 2003. I am trying to add the amount of X's in my
excel and seperate them by the YEAR/WK.

For example I want to know how many X's I have for 200948. For this
function I dont care about the column they are in just how many X's there
are. My sheet is much larger than the one below but it is a sample. I
understand I will have to have a new function per pln_s_yrwk. Any help
would be great!!



yrwk SOC OPC PUR M. PLN
D. PLN
200948 0 0 0 x 0
200951 0 x 0 0 0
200948 0 0 0 x x
200947 0 0 x 0 0
200946 0 0 0 0 x


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
Multiple Criteria, Count If, Sum Product to get count across range Jonathan Excel Worksheet Functions 5 January 9th 08 11:32 PM
Count Employee Work Time - Don't Double-count Overlapping Apts. J Excel Worksheet Functions 0 April 27th 07 05:52 AM
Excel 2000, count, sort a list & count totals? sunslight Excel Worksheet Functions 1 April 9th 07 05:46 PM
How do i count numbers and letters to find a total count of all Linda Excel Worksheet Functions 4 November 10th 05 04:51 PM
Count Intervals of Filtered TEXT values in Column and Return Count across a Row Sam via OfficeKB.com Excel Worksheet Functions 9 July 31st 05 03:37 AM


All times are GMT +1. The time now is 02:03 AM.

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

About Us

"It's about Microsoft Excel"