View Single Post
  #11   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Dave Peterson Dave Peterson is offline
external usenet poster
 
Posts: 35,218
Default COUNTIF question

I misread your point.

Try it first. Post back if it doesn't work correctly.

Jock wrote:

Surely that'll only show either 'blank' or '1'?
--
Traa Dy Liooar

Jock

"Dave Peterson" wrote:

In B1:

=if(sumproduct(--(trim(A$1:A1)=trim(A1)))1,"",
sumproduct(--(trim(A$1:A$700)=trim(A1))))

And copied down.



Jock wrote:

Thinking further, if a name were to appear, say six times, would it be
possible to only show the result aagainst the first entry rather than all
six? (The names are listed by fastest times in ascending order, not
alphabetically)
--
Traa Dy Liooar

Jock

"Dave Peterson" wrote:

I missed a note:

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

=sumproduct() likes to work with numbers. The -- stuff changes trues and falses
to 1's and 0's.

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

And J.E. McGimpsey has some notes at:
http://mcgimpsey.com/excel/formulae/doubleneg.html



Jock wrote:

With =COUNTIF(A1:A700,A1) in cell B1 and copied down, entries which have a
space after the final letter are, quite correctly, treated as a different
word and therefore not included in the total for a particular word. IE:

[testing] and [testing ] are treated as different words. (brackets to show
the space)
How can I adapt the formula to ignore any space after the final letter in
the cell?

Thanks,

--
Traa Dy Liooar

Jock

--

Dave Peterson


--

Dave Peterson


--

Dave Peterson