Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 7
Default How to count occurrences where 2 columns are required to be true?

I am trying to count the number of occurences when conditions in two columns
are met. I can count each individual column values with =countif function.
But, I can't seem to count only if a value is found in both column A and B to
be true. Please see example below.

A1= Tom B1=Job
A2= John B2=Job
A3= John B3=Spec
A4= Mark B4=Spec
A5= Alice B5=Spec
A6= Tom B6=Spec

What I would like to count is the number of "Jobs" each person has versus
"Spec" jobs.

For example: If I count the number of jobs Tom is working on = 2
(COUNTIF(A:A,"Tom"). But I also want to return the number of Spec jobs only
Tom is working on = 1 (This is the formula I need. Basically, count each row
that has Tom and Spec as TRUE).

Thank you in advance for your help. Please email copy your response.
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 709
Default How to count occurrences where 2 columns are required to be true?

Brandoni, here is one way,

=SUMPRODUCT((A1:A25="Tom")*(B1:B25="Job"))

--
Paul B
Always backup your data before trying something new
Please post any response to the newsgroups so others can benefit from it
Feedback on answers is always appreciated!
Using Excel 2002 & 2003

"Brandoni" wrote in message
...
I am trying to count the number of occurences when conditions in two

columns
are met. I can count each individual column values with =countif

function.
But, I can't seem to count only if a value is found in both column A and B

to
be true. Please see example below.

A1= Tom B1=Job
A2= John B2=Job
A3= John B3=Spec
A4= Mark B4=Spec
A5= Alice B5=Spec
A6= Tom B6=Spec

What I would like to count is the number of "Jobs" each person has versus
"Spec" jobs.

For example: If I count the number of jobs Tom is working on = 2
(COUNTIF(A:A,"Tom"). But I also want to return the number of Spec jobs

only
Tom is working on = 1 (This is the formula I need. Basically, count each

row
that has Tom and Spec as TRUE).

Thank you in advance for your help. Please email copy your response.



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
Using COUNTIF to search for existence Epinn Excel Worksheet Functions 31 October 27th 06 04:57 AM
How do I count values across multiple columns? [email protected] Excel Worksheet Functions 4 March 21st 06 11:13 PM
counting in one column when two expressions in two other columns are true Henrik Excel Worksheet Functions 3 December 1st 04 04:28 PM
Nexsted if across 3 columns Felicity Geronimo Excel Worksheet Functions 4 November 17th 04 11:08 AM
Count certain changes between columns SLB Excel Worksheet Functions 1 November 1st 04 08:54 PM


All times are GMT +1. The time now is 08:43 PM.

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"