Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1
Default Countif with nested function not working?


I'm attempting a countif that reads - COUNTIF(A:A,LEFT(A:A,1)=X)
Where column A looks something like:
XYZ
MNOP
XMN
LKJ
XTR

What's the proper way to do this?
Thanks!


--
jshuatree
------------------------------------------------------------------------
jshuatree's Profile: http://www.excelforum.com/member.php...o&userid=36459
View this thread: http://www.excelforum.com/showthread...hreadid=562227

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 4,624
Default Countif with nested function not working?

One way:

=COUNTIF(A:A,"X*")

In article ,
jshuatree
wrote:

I'm attempting a countif that reads - COUNTIF(A:A,LEFT(A:A,1)=X)
Where column A looks something like:
XYZ
MNOP
XMN
LKJ
XTR

What's the proper way to do this?
Thanks!

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1
Default Countif with nested function not working?


That helps but I should have also mentioned that my next step would be
to count those entries whose first letter was not X but also included
some other variable ie. ended with an O or had a integer greater than
some amount.
I don't think this simple method will allow me to do this. As long as
I can figure out how to get the nested function to work properly I can
manage the rest.


--
jshuatree
------------------------------------------------------------------------
jshuatree's Profile: http://www.excelforum.com/member.php...o&userid=36459
View this thread: http://www.excelforum.com/showthread...hreadid=562227

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 4,624
Default Countif with nested function not working?

There is no nesting method with COUNTIF.

=COUNTIF(A:A,"X*") + COUNTIF(A:A, "*0") - COUNTIF(A:A,"X*0")

Or you could use the array-entered (CTRL-SHIFT-ENTER or CMD-RETURN):

=SUM((LEFT(A1:A1000,1)="X") + ((LEFT(A1:A1000,1)<"X") *
(RIGHT(A1:A1000,1)="0")))


In article ,
jshuatree
wrote:

That helps but I should have also mentioned that my next step would be
to count those entries whose first letter was not X but also included
some other variable ie. ended with an O or had a integer greater than
some amount.
I don't think this simple method will allow me to do this. As long as
I can figure out how to get the nested function to work properly I can
manage the rest.

  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,688
Default Countif with nested function not working?

=SUMPRODUCT(--(LEFT(A1:A10)<"X"),--(RIGHT(A1:A10)="O"))

or had a integer greater than some amount.


You'll need to post some examples so we can see what you mean.

Biff

"jshuatree" wrote
in message ...

That helps but I should have also mentioned that my next step would be
to count those entries whose first letter was not X but also included
some other variable ie. ended with an O or had a integer greater than
some amount.
I don't think this simple method will allow me to do this. As long as
I can figure out how to get the nested function to work properly I can
manage the rest.


--
jshuatree
------------------------------------------------------------------------
jshuatree's Profile:
http://www.excelforum.com/member.php...o&userid=36459
View this thread: http://www.excelforum.com/showthread...hreadid=562227





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
COUNTIF Subtotal Function? jcpotwor Excel Discussion (Misc queries) 2 January 12th 06 01:56 PM
Countif Function, complex criteria Tomski Excel Worksheet Functions 4 January 9th 06 03:45 PM
Will a Nested IF/SUMIF function instead of VBA? Ronny Hamida Excel Worksheet Functions 5 January 3rd 06 10:31 PM
Nested IF Function and VLookup Alternatives robert.holmes Excel Worksheet Functions 1 December 12th 05 10:28 PM
Function Macro for Nested IF Qaspec Excel Worksheet Functions 5 March 10th 05 07:25 PM


All times are GMT +1. The time now is 07:27 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"