Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
San San is offline
external usenet poster
 
Posts: 14
Default Countif depending on the conditions across multiple columns

How can I count the no. of rows in a sheet depending on the values in 2
columns ?

Eg:
Suppose I have two columns in an excel sheet viz

ColA ColB
1 1
2 1
1 2
2 1
1 2
2 0
2 1


I want to count the nos. of 1's in colB iif value in colA for the same row
is "2" ?
I dont want to use a filter.

Result for above example should be:
The count result for the above example should be 3 due to following 3 rows
ColA ColB
2 1
2 1
2 1
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 79
Default Countif depending on the conditions across multiple columns

On May 20, 12:01*pm, san wrote:
How can I count the no. of rows in a sheet depending on the values in *2
columns ?

Eg:
Suppose I have two columns in an excel sheet viz

ColA * ColB
1 * * * 1
2 * * * 1
1 * * * 2
2 * * * 1
1 * * * 2
2 * * * 0
2 * * * 1

I want to count the nos. of 1's in colB iif value in colA for the same row
is "2" ?
I dont want to use a filter.

Result for above example should be:
The count result for the above example should be 3 due to following 3 rows
ColA * ColB
2 * * * 1
2 * * * 1
2 * * * 1


Use SUMPRODUCT:

=SUMPRODUCT((A1:A7=2)*(B1:B7=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
Countif with multiple conditions torooo Excel Discussion (Misc queries) 5 December 7th 07 07:03 PM
CountIf multiple conditions ashg657 Excel Worksheet Functions 2 March 12th 07 08:55 AM
Countif with Multiple Not Conditions Chart_Maker_Wonderer Excel Discussion (Misc queries) 12 March 8th 07 06:55 AM
CountIf with multiple conditions Thor Excel Worksheet Functions 2 September 22nd 06 08:59 PM
COUNTIF - multiple conditions allphin Excel Worksheet Functions 4 September 18th 05 04:05 PM


All times are GMT +1. The time now is 09:01 PM.

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"