#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Cul Cul is offline
external usenet poster
 
Posts: 3
Default Counting Column

I am trying to get a count of how many items in a spreadsheet I have an
example below. Basically if the number is listed more than once then it is a
part to an assembly and it only needs to be counted once so for the below
data it would return the number 8 because there are only 8 diffrent numbers.

PS-AA1-120
PS-AA1-120
PS-AA1-121
PS-AA1-121
PS-AA1-122
PS-AA1-122
PS-AA1-123
PS-AA1-123
PS-AA2-001
PS-AA2-001
PS-AA2-002
PS-AA2-002
PS-AA2-002
PS-AA2-003
PS-AA2-003
PS-AA2-004
PS-AA2-004
PS-AA2-004

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8,520
Default Counting Column

With your data in Col; try the below formula which will give you the distinct
count

=SUMPRODUCT(--(A1:A10<""),1/COUNTIF(A1:A10,A1:A10&""))

If this post helps click Yes
---------------
Jacob Skaria


"Cul" wrote:

I am trying to get a count of how many items in a spreadsheet I have an
example below. Basically if the number is listed more than once then it is a
part to an assembly and it only needs to be counted once so for the below
data it would return the number 8 because there are only 8 diffrent numbers.

PS-AA1-120
PS-AA1-120
PS-AA1-121
PS-AA1-121
PS-AA1-122
PS-AA1-122
PS-AA1-123
PS-AA1-123
PS-AA2-001
PS-AA2-001
PS-AA2-002
PS-AA2-002
PS-AA2-002
PS-AA2-003
PS-AA2-003
PS-AA2-004
PS-AA2-004
PS-AA2-004

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3,346
Default Counting Column

Hi,

Any of the following may work

=SUM(1/COUNTIF(A1:A18,A1:A18)) array entered

array - press Shift+Ctrl+Enter to enter the formula

=SUMPRODUCT(1/COUNTIF(A1:A18,A1:A18)) no array needed.

--
If this helps, please click the Yes button.

Cheers,
Shane Devenshire


"Cul" wrote:

I am trying to get a count of how many items in a spreadsheet I have an
example below. Basically if the number is listed more than once then it is a
part to an assembly and it only needs to be counted once so for the below
data it would return the number 8 because there are only 8 diffrent numbers.

PS-AA1-120
PS-AA1-120
PS-AA1-121
PS-AA1-121
PS-AA1-122
PS-AA1-122
PS-AA1-123
PS-AA1-123
PS-AA2-001
PS-AA2-001
PS-AA2-002
PS-AA2-002
PS-AA2-002
PS-AA2-003
PS-AA2-003
PS-AA2-004
PS-AA2-004
PS-AA2-004

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
Counting a Column Jamakinmecrazy Excel Worksheet Functions 7 January 1st 09 08:53 PM
Counting items in one column based on criteria in another column luttona Excel Worksheet Functions 3 June 13th 08 06:00 PM
Counting entries in column based on condition in another column RobertR Excel Worksheet Functions 1 February 8th 07 03:54 PM
Formula help for counting,with a column of dates and a column of n Altstatten Excel Worksheet Functions 2 December 8th 05 09:32 PM
Counting names in a column but counting duplicate names once TBoe Excel Discussion (Misc queries) 9 May 11th 05 11:24 PM


All times are GMT +1. The time now is 05:01 PM.

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"