View Single Post
  #16   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Mary-Lou
 
Posts: n/a
Default Need help with Countif function

OK - I finally got it working. Apparently the functions are really picky
about where the rows start. I entered row 9 in the formula, but had inserted
2 extra blank rows in 9 and 10, moving the data down to row 11. I decided to
re-enter the range into the formula and voila - it worked.

Thanks for your help and patience.



"Mary-Lou" wrote:

I finally have the following 2 separate functions working but still working
on putting them together. Here's what I have:

Part 1: =SUMPRODUCT(--(ISNUMBER(SEARCH("*AM *",E9:E600))))
(looking for any row that contains "AM " within the column)
Part 2: =SUMPRODUCT(--(H9:H600="channels"))

Here's what I have as one formula - that still returns 0:
=SUMPRODUCT(--(ISNUMBER(SEARCH("*AM *",E9:E600))),--(H9:H600="channels"))


"Mary-Lou" wrote:

Hi. I was able to get Max's formula to work, but I am unable to get yours to
work. The two functions are different. I'm still working on getting your
version up and running... it's bugging me now why it won't work.

"Biff" wrote:

I'm confused.........

You're reply to Max says you got it working. Is it working or not?

The only difference, other than syntax, between mine and Max's formulas is
the use of the TRIM function on the criteria cells.

Biff

"Mary-Lou" wrote in message
...
I broke it out, and I get results with the first one OK, but get 0 on the
seond one (but when editting the function, the formula displays a value).

"Biff" wrote:

Hi!

Try breaking the formula into 2 formulas and see what you get:

Formula to count just column A:

=SUMPRODUCT(--(ISNUMBER(SEARCH("XX",A1:A100))))

Formula to count just column B:

=SUMPRODUCT(--(B1:B100="XXXX"))

Do either of these return 0?

Biff

"Mary-Lou" wrote in message
...
Thanks. I'm getting the same results when I tried the array Max
included - 0
value displays within the cell, but when editting the function, the
formula
results display a value.

The sentences within Column A can be really wonky and could be very
long -
can the funny results be because of the data within Column A?

"Biff" wrote:

Hi!

Try this:

=SUMPRODUCT(--(ISNUMBER(SEARCH("XX",A1:A100))),--(B1:B100="XXXX"))

Biff

"Mary-Lou" wrote in message
...
I need to count two different text values within two columns.

Column A contains sentences and Column B contains various values.

Example of small sentences in Column A:
Custom XX Upgrade
Printing reports on XX
Custom YY Upgrade

Example of values in Column B:
AAAA
BBBB
BBBB

What I need to do is count groups of records, like only counting the
records
that contain "XX" anyplace witihin Column A plus have "XXXX" in
Column
B.

I tried countif statements with no success. Any ideas?