#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 26
Default COUNTIF HELP

I am having major trouble with a countif formula

My Sheet looks like this

A B C D
1 Call AM 136
2 Call AM 50
3 Net AM 38
4 Call CU 150
5 Net CU 32
6 Net CU 12
7 Call EF 145

I want another cell to do the following: COUNTIF B1:B600 = "AM", COUNT THE
AMOUNT OF CELLS THAT ARE OVER 30.

also figured to throw this in the mix too - IF A1:A600 = Call and B1:B600 is
"Am", Count THE AMOUNT OF CELLS THAT ARE OVER 30.


The problem with this is that I have two worksheets full of this data and i
have about 80 "UNITS (i.e. AM, CU)" that I am working with... so manually
counting them is kind of out of the question.


Thanks again everyone

--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...excel/200705/1

  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default COUNTIF HELP

=sumproduct(--(b1:b600="AM"),--(c1:c60030))
and
=sumproduct(--(a1:a600="Call"),--(b1:b600="AM"),--(c1:c60030))

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

==========
You may want to add headers (in row 1) and add a formula in column D.

Formula in D2:
=if(c230,1,0)
and drag down

Then you could use that table to create a pivottable.

Select the table (a1:D601)
data|pivottable
follow the wizard until you get to a step with a Layout button on it.
Click that button.

Drag the header for Column A to the Row field
Drag the header for column B to the column field
drag the header for column D to the Data field
If the header for column D doesn't show "Sum of" Cancel this and go back to the
original table and make sure your formula is correct in D2:D601.

Then finish up this pivottable.



"instereo911 via OfficeKB.com" wrote:

I am having major trouble with a countif formula

My Sheet looks like this

A B C D
1 Call AM 136
2 Call AM 50
3 Net AM 38
4 Call CU 150
5 Net CU 32
6 Net CU 12
7 Call EF 145

I want another cell to do the following: COUNTIF B1:B600 = "AM", COUNT THE
AMOUNT OF CELLS THAT ARE OVER 30.

also figured to throw this in the mix too - IF A1:A600 = Call and B1:B600 is
"Am", Count THE AMOUNT OF CELLS THAT ARE OVER 30.

The problem with this is that I have two worksheets full of this data and i
have about 80 "UNITS (i.e. AM, CU)" that I am working with... so manually
counting them is kind of out of the question.

Thanks again everyone

--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...excel/200705/1


--

Dave Peterson
  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 26
Default COUNTIF HELP

Dave-

Thank you very very much!!! This worked like a charm!!

Dave Peterson wrote:
=sumproduct(--(b1:b600="AM"),--(c1:c60030))
and
=sumproduct(--(a1:a600="Call"),--(b1:b600="AM"),--(c1:c60030))

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

==========
You may want to add headers (in row 1) and add a formula in column D.

Formula in D2:
=if(c230,1,0)
and drag down

Then you could use that table to create a pivottable.

Select the table (a1:D601)
data|pivottable
follow the wizard until you get to a step with a Layout button on it.
Click that button.

Drag the header for Column A to the Row field
Drag the header for column B to the column field
drag the header for column D to the Data field
If the header for column D doesn't show "Sum of" Cancel this and go back to the
original table and make sure your formula is correct in D2:D601.

Then finish up this pivottable.

I am having major trouble with a countif formula

[quoted text clipped - 24 lines]
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...excel/200705/1



--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...excel/200705/1

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
How do I use a countif function according to two other countif fu. Kirsty Excel Worksheet Functions 2 February 20th 06 11:44 AM
edit this =COUNTIF(A1:F16,"*1-2*")+COUNTIF(A1:F16,"*2-1*") sctroy Excel Discussion (Misc queries) 2 September 25th 05 04:13 AM
COUNTIF or not to COUNTIF on a range in another sheet Ellie Excel Worksheet Functions 4 September 15th 05 10:06 PM
Countif Jeanette Excel Worksheet Functions 3 August 5th 05 08:49 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 12:37 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"