">="&

  • Thread starter Thread starter Angel160
  • Start date Start date
A

Angel160

For some of the queries that I have posted, people have very kindl
given me the correct formulae to use. Some of these have included
(for example
=countif(A1:A100,">="&date(2004,9,1))-countif(A1:A100,">"&date(2004,9,30))
Please could someone tell me what the & actually does and how best t
use it?

Thank you
 
Angel160 said:
For some of the queries that I have posted, people have very kindl
given me the correct formulae to use. Some of these have included
(for example
=countif(A1:A100,">="&date(2004,9,1))-countif(A1:A100,">"&date(2004,9,30))
Please could someone tell me what the & actually does and how best t
use it?

Thank you.

The "&" is an operator that joins two items (it is the shortcut versio
of concatenate). The items can be text strings, numbers or a cel
reference.

As an example, if cell A1 contains the word "Hello" and Cell B
contains the word "Dolly" and you would like to join them in Cell C1
then the formula that you will use is

=A1&""&B1

Hope this helps you
 
I find it nicer to write the formula that way.

If you wanted to count just the cells >=6, you could use
=countif(a1:a999,">=6")

But this becomes a problem when that 6 is placed into another cell (say C1) and
the formula has to change to look at C1:

This would give incorrect results:

=countif(a1:a999,">=C1")

It will try to find the cells which are >= the string "C1"--not what's in that
C1 Cell.

So by using the ampersand to concatenate, you can use:
=countif(a1:a999,">="&c1)

And that means to grab what's in C1 and use it to evaluate the formula.
 
Back
Top