Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2
Default Count rows with criteria from two columns?

Using Excel 2007 under XP Pro SP3.

I'm new to Excel and spreadsheets in general, so maybe this belongs
under excel.newusers, but a google search didn't show anything that
looked right.

I have two columns of alpha data, each cell can contain "A", "B" or be
blank.

I need formulas to count

1. In how many rows are either or both cells non-blank.
2. In how many rows does either or both cells have the value "A"

--
Bert Hyman St. Paul, MN
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 15,768
Default Count rows with criteria from two columns?

Try these:

1. In how many rows are either or both cells non-blank.


=SUMPRODUCT(--((A1:A10<"")+(B1:B10<"")0))

2. In how many rows does either or both cells have the value "A"


=SUMPRODUCT(--((A1:A10="A")+(B1:B10="A")0))

--
Biff
Microsoft Excel MVP


"Bert Hyman" wrote in message
...
Using Excel 2007 under XP Pro SP3.

I'm new to Excel and spreadsheets in general, so maybe this belongs
under excel.newusers, but a google search didn't show anything that
looked right.

I have two columns of alpha data, each cell can contain "A", "B" or be
blank.

I need formulas to count

1. In how many rows are either or both cells non-blank.
2. In how many rows does either or both cells have the value "A"

--
Bert Hyman St. Paul, MN



  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2
Default Count rows with criteria from two columns?

In "T. Valko"
wrote:

Try these:

1. In how many rows are either or both cells non-blank.


=SUMPRODUCT(--((A1:A10<"")+(B1:B10<"")0))

2. In how many rows does either or both cells have the value "A"


=SUMPRODUCT(--((A1:A10="A")+(B1:B10="A")0))


That seems to be the answer.

I'll admit that I'm still somewhat baffled by the SUMPRODUCT function,
but maybe now with some personally meaningful data, I can figure it out.

--
Bert Hyman St. Paul, MN
  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 15,768
Default Count rows with criteria from two columns?

Thanks for the feedback!

See this for more on SUMPRODUCT:

http://xldynamic.com/source/xld.SUMPRODUCT.html

--
Biff
Microsoft Excel MVP


"Bert Hyman" wrote in message
...
In "T. Valko"
wrote:

Try these:

1. In how many rows are either or both cells non-blank.


=SUMPRODUCT(--((A1:A10<"")+(B1:B10<"")0))

2. In how many rows does either or both cells have the value "A"


=SUMPRODUCT(--((A1:A10="A")+(B1:B10="A")0))


That seems to be the answer.

I'll admit that I'm still somewhat baffled by the SUMPRODUCT function,
but maybe now with some personally meaningful data, I can figure it out.

--
Bert Hyman St. Paul, MN



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
Count based on criteria from two different columns ba374 Excel Discussion (Misc queries) 2 November 13th 07 04:41 PM
Count where criteria in 2 columns are met [email protected][_2_] Excel Discussion (Misc queries) 9 September 14th 07 12:04 AM
Need to count based on different criteria in two columns Adlin Excel Worksheet Functions 3 May 25th 07 08:05 PM
count rows that meet two criteria in two different columns? dsk3808 Excel Worksheet Functions 6 June 28th 06 09:18 PM
Count Rows with two criteria Eli Waite Excel Worksheet Functions 3 March 8th 05 10:38 PM


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