#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 5
Default COUNTIF quandry

I've got this:
=COUNTIF(SWABS!F7:F237,"=*Station 1*")

How can I add =COUNTIF(SWABS!L7:L237,"=*F*")

to this to make it all work? In other words I want to count the number of
"Station 1" values and the number of "F" corresponding values.

THANKS!

--
www.Marzetti.com
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 10,593
Default COUNTIF quandry

=SUMPRODUCT(--(ISNUMBER(FIND("Station
1",SWABS!F7:F237))),--(ISNUMBER(FIND("F",,SWABS!L7:L237))))


--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)



"JohnLute" wrote in message
...
I've got this:
=COUNTIF(SWABS!F7:F237,"=*Station 1*")

How can I add =COUNTIF(SWABS!L7:L237,"=*F*")

to this to make it all work? In other words I want to count the number of
"Station 1" values and the number of "F" corresponding values.

THANKS!

--
www.Marzetti.com



  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,231
Default COUNTIF quandry

"Bob Phillips" wrote...
=SUMPRODUCT(--(ISNUMBER(FIND("Station 1",SWABS!F7:F237))),
--(ISNUMBER(FIND("F",,SWABS!L7:L237))))

....

Note the ,, typo.

Or use just one ISNUMBER call.

=SUMPRODUCT(--ISNUMBER(FIND("Station 1",SWABS!F7:F237)
+FIND("F",SWABS!L7:L237)))

or, if the OP could suffer an array formula,

=COUNT(FIND("Station 1",SWABS!F7:F237)+FIND("F",SWABS!L7:L237))

No magic in using +. - * / would work equally well. ^ might overflow.


  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 5
Default COUNTIF quandry

Thanks, Bob! That's not returning what's expected. It's returning "0" when
there's actually 2 "F's".

In other words for all of the "Station 1" entries (8 total) there are only 2
that have "F's". I'm not sure what needs changed...?

--
www.Marzetti.com


"Bob Phillips" wrote:

=SUMPRODUCT(--(ISNUMBER(FIND("Station
1",SWABS!F7:F237))),--(ISNUMBER(FIND("F",,SWABS!L7:L237))))


--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)



"JohnLute" wrote in message
...
I've got this:
=COUNTIF(SWABS!F7:F237,"=*Station 1*")

How can I add =COUNTIF(SWABS!L7:L237,"=*F*")

to this to make it all work? In other words I want to count the number of
"Station 1" values and the number of "F" corresponding values.

THANKS!

--
www.Marzetti.com




  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
KL KL is offline
external usenet poster
 
Posts: 201
Default COUNTIF quandry

"JohnLute" wrote in message
...
I've got this:
=COUNTIF(SWABS!F7:F237,"=*Station 1*")

How can I add =COUNTIF(SWABS!L7:L237,"=*F*")

to this to make it all work? In other words I want to count the number of
"Station 1" values and the number of "F" corresponding values.

THANKS!

--
www.Marzetti.com


If you need to count either those that include "Station 1" or those that
include "F", then:

=SUMPRODUCT(COUNTIF(SWABS!F7:F237,{"*Station 1*","*F*"}))

--
KL
[MVP - Microsoft Excel]
RU: http://www.mvps.ru/Program/Default.aspx
ES: http://mvp.support.microsoft.com/?LN=es-es
EN: http://mvp.support.microsoft.com/?LN=en-us
Profile: http://mvp.support.microsoft.com/profile/Kirill



  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 5
Default COUNTIF quandry

Thanks very much, Harlan!

--
www.Marzetti.com


"Harlan Grove" wrote:

"Bob Phillips" wrote...
=SUMPRODUCT(--(ISNUMBER(FIND("Station 1",SWABS!F7:F237))),
--(ISNUMBER(FIND("F",,SWABS!L7:L237))))

....

Note the ,, typo.

Or use just one ISNUMBER call.

=SUMPRODUCT(--ISNUMBER(FIND("Station 1",SWABS!F7:F237)
+FIND("F",SWABS!L7:L237)))

or, if the OP could suffer an array formula,

=COUNT(FIND("Station 1",SWABS!F7:F237)+FIND("F",SWABS!L7:L237))

No magic in using +. - * / would work equally well. ^ might overflow.



  #7   Report Post  
Posted to microsoft.public.excel.worksheet.functions
KL KL is offline
external usenet poster
 
Posts: 201
Default COUNTIF quandry

Upps! I guess I misunderstood the question...

"KL" wrote
If you need to count either those that include "Station 1" or those that
include "F", then:

=SUMPRODUCT(COUNTIF(SWABS!F7:F237,{"*Station 1*","*F*"}))


KL
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
Multivariable Data Spreadsheet Quandry joebags Excel Discussion (Misc queries) 0 April 11th 06 05:44 PM
COUNTIF or not to COUNTIF on a range in another sheet Ellie Excel Worksheet Functions 4 September 15th 05 10:06 PM
Macro Quandry Desiree Excel Discussion (Misc queries) 2 July 29th 05 01:32 PM
macro quandry.....?? Daesthai Excel Discussion (Misc queries) 2 June 29th 05 07:29 PM
COUNTIF in one colum then COUNTIF in another...??? JonnieP Excel Worksheet Functions 3 February 22nd 05 02:55 PM


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