#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 16
Default count if formula

Hi
I wondered if anyone knew the formula for the following:-

If A5:A10 = A1, then count C5:C10, but do not count duplicate information
(such as there being 1234 in both call C5 and C6, only count this as 1)

Thank you
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 15,768
Default count if formula

In other words, count the unique *numbers* in C5:C10 where A5:A10 = A1?

If that's what you want try this array formula** :

=COUNT(1/FREQUENCY(IF(A5:A10=A1,B5:B10),B5:B10))

** array formulas need to be entered using the key combination of
CTRL,SHIFT,ENTER (not just ENTER). Hold down both the CTRL key and the SHIFT
key then hit ENTER.

--
Biff
Microsoft Excel MVP


"Fiona Yorke-Saville" wrote in
message ...
Hi
I wondered if anyone knew the formula for the following:-

If A5:A10 = A1, then count C5:C10, but do not count duplicate information
(such as there being 1234 in both call C5 and C6, only count this as 1)

Thank you



  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 15,768
Default count if formula

Ooops!

=COUNT(1/FREQUENCY(IF(A5:A10=A1,B5:B10),B5:B10))


I used the wrong column references!

Should be:

=COUNT(1/FREQUENCY(IF(A5:A10=A1,C5:C10),C5:C10))


--
Biff
Microsoft Excel MVP


"T. Valko" wrote in message
...
In other words, count the unique *numbers* in C5:C10 where A5:A10 = A1?

If that's what you want try this array formula** :

=COUNT(1/FREQUENCY(IF(A5:A10=A1,B5:B10),B5:B10))

** array formulas need to be entered using the key combination of
CTRL,SHIFT,ENTER (not just ENTER). Hold down both the CTRL key and the
SHIFT key then hit ENTER.

--
Biff
Microsoft Excel MVP


"Fiona Yorke-Saville" wrote
in message ...
Hi
I wondered if anyone knew the formula for the following:-

If A5:A10 = A1, then count C5:C10, but do not count duplicate information
(such as there being 1234 in both call C5 and C6, only count this as 1)

Thank you





  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 16
Default count if formula

Thanks Biff, thats definately what I want to do, but when I enter it on to my
spreadsheet it returns a zeor when there should be 3....any ideas??

The formula makes sense for what I want to do

Fiona

"T. Valko" wrote:

Ooops!

=COUNT(1/FREQUENCY(IF(A5:A10=A1,B5:B10),B5:B10))


I used the wrong column references!

Should be:

=COUNT(1/FREQUENCY(IF(A5:A10=A1,C5:C10),C5:C10))


--
Biff
Microsoft Excel MVP


"T. Valko" wrote in message
...
In other words, count the unique *numbers* in C5:C10 where A5:A10 = A1?

If that's what you want try this array formula** :

=COUNT(1/FREQUENCY(IF(A5:A10=A1,B5:B10),B5:B10))

** array formulas need to be entered using the key combination of
CTRL,SHIFT,ENTER (not just ENTER). Hold down both the CTRL key and the
SHIFT key then hit ENTER.

--
Biff
Microsoft Excel MVP


"Fiona Yorke-Saville" wrote
in message ...
Hi
I wondered if anyone knew the formula for the following:-

If A5:A10 = A1, then count C5:C10, but do not count duplicate information
(such as there being 1234 in both call C5 and C6, only count this as 1)

Thank you






  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 15,768
Default count if formula

Did you enter the formula as an array?

Array formulas are entered differently than a regular formula. After you
type in a regular formula you hit the ENTER key. With an array formula you
*must* use a combination of keys. Those keys are the CTRL key, the SHIFT key
and the ENTER key. That is, hold down both the CTRL key and the SHIFT key
then hit the ENTER key.

Also, any time you edit or change an array formula it must be re-entered as
an array using the key combination.

Another possibility: your numbers really aren't numbers. They may look like
numbers but are actually TEXT. Numeric numbers and TEXT numbers look the
same to you and me but Excel sees them differently. You can test by trying
this formula:

=COUNT(C5:C10)

That will return the count of real numeric numbers in the range.

--
Biff
Microsoft Excel MVP


"Fiona Yorke-Saville" wrote in
message ...
Thanks Biff, thats definately what I want to do, but when I enter it on to
my
spreadsheet it returns a zeor when there should be 3....any ideas??

The formula makes sense for what I want to do

Fiona

"T. Valko" wrote:

Ooops!

=COUNT(1/FREQUENCY(IF(A5:A10=A1,B5:B10),B5:B10))


I used the wrong column references!

Should be:

=COUNT(1/FREQUENCY(IF(A5:A10=A1,C5:C10),C5:C10))


--
Biff
Microsoft Excel MVP


"T. Valko" wrote in message
...
In other words, count the unique *numbers* in C5:C10 where A5:A10 = A1?

If that's what you want try this array formula** :

=COUNT(1/FREQUENCY(IF(A5:A10=A1,B5:B10),B5:B10))

** array formulas need to be entered using the key combination of
CTRL,SHIFT,ENTER (not just ENTER). Hold down both the CTRL key and the
SHIFT key then hit ENTER.

--
Biff
Microsoft Excel MVP


"Fiona Yorke-Saville"
wrote
in message ...
Hi
I wondered if anyone knew the formula for the following:-

If A5:A10 = A1, then count C5:C10, but do not count duplicate
information
(such as there being 1234 in both call C5 and C6, only count this as
1)

Thank you







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
Count Formula - Count Ticks LittleAnn Excel Discussion (Misc queries) 3 May 8th 23 07:44 PM
count formula mdcgpw Excel Worksheet Functions 2 January 13th 09 07:45 PM
is there a formula to count something like this.... driller Excel Worksheet Functions 3 July 6th 07 07:16 PM
Trying to construct a count count formula Chris K Excel Discussion (Misc queries) 6 May 26th 07 07:20 PM
Count formula Help... nosaj_enryb Excel Discussion (Misc queries) 3 November 11th 05 10:40 AM


All times are GMT +1. The time now is 11:44 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"