Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 26
Default Formula for multiple countifs

Hi,
I would really appreciate anybodys expertise with the following 2 formulas;
I have a worksheet that looks a bit like this - (A is days taken to deliver
- B is method for delivery)

A B
1 sec *I need to be able to count the number of cells in A
that contain
1 sig a '1' but only if they have either 'sec','sig' or
'del' in column B.
1 sec
1 man **Then I need to count the number of cells in A that
are greater 1 del or equal to '4' but DONT contain 'sec',
'sig' or 'del'.
2 sec
2 sig Note there are several more possible values that
turn up in B,
3 sec do I need to let you have all of these too?
3 van
3 sec
3 dup
4 sig
4 man
7 sig

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,276
Default Formula for multiple countifs

Hi,
for your 1st question use

=SUMPRODUCT((A1:A2=1)*(B1:B2="Sec")*(B1:B2="Sig")* (B1:B2="Del"))

to your 2nd

=SUMPRODUCT((A1:A21)*(A1:A2<=4)*(B1:B2<"Sec")*(B 1:B2<"Sig")*(B1:B2<"Del"))







"J.Scargill" wrote:

Hi,
I would really appreciate anybodys expertise with the following 2 formulas;
I have a worksheet that looks a bit like this - (A is days taken to deliver
- B is method for delivery)

A B
1 sec *I need to be able to count the number of cells in A
that contain
1 sig a '1' but only if they have either 'sec','sig' or
'del' in column B.
1 sec
1 man **Then I need to count the number of cells in A that
are greater 1 del or equal to '4' but DONT contain 'sec',
'sig' or 'del'.
2 sec
2 sig Note there are several more possible values that
turn up in B,
3 sec do I need to let you have all of these too?
3 van
3 sec
3 dup
4 sig
4 man
7 sig
Hi

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 26
Default Formula for multiple countifs

Hi Eduardo,

Thanks, but the first formula returns a zero. Any ideas why?? There are
blank cells in the colums, does that matter?? The actual range i am using is
A3:A10000, does this matter??



"Eduardo" wrote:

Hi,
for your 1st question use

=SUMPRODUCT((A1:A2=1)*(B1:B2="Sec")*(B1:B2="Sig")* (B1:B2="Del"))

to your 2nd

=SUMPRODUCT((A1:A21)*(A1:A2<=4)*(B1:B2<"Sec")*(B 1:B2<"Sig")*(B1:B2<"Del"))







"J.Scargill" wrote:

Hi,
I would really appreciate anybodys expertise with the following 2 formulas;
I have a worksheet that looks a bit like this - (A is days taken to deliver
- B is method for delivery)

A B
1 sec *I need to be able to count the number of cells in A
that contain
1 sig a '1' but only if they have either 'sec','sig' or
'del' in column B.
1 sec
1 man **Then I need to count the number of cells in A that
are greater 1 del or equal to '4' but DONT contain 'sec',
'sig' or 'del'.
2 sec
2 sig Note there are several more possible values that
turn up in B,
3 sec do I need to let you have all of these too?
3 van
3 sec
3 dup
4 sig
4 man
7 sig
Hi

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8,520
Default Formula for multiple countifs

Try

'1st
=SUMPRODUCT((A1:A100=1)*(B1:B100={"sec","sig","del "}))

'and 2nd
=SUMPRODUCT((A1:A1001)*(A1:A100<=4)*
(ISNA(MATCH(B1:B100,{"sec","sig","del"},0))))

--
Jacob


"J.Scargill" wrote:

Hi,
I would really appreciate anybodys expertise with the following 2 formulas;
I have a worksheet that looks a bit like this - (A is days taken to deliver
- B is method for delivery)

A B
1 sec *I need to be able to count the number of cells in A
that contain
1 sig a '1' but only if they have either 'sec','sig' or
'del' in column B.
1 sec
1 man **Then I need to count the number of cells in A that
are greater 1 del or equal to '4' but DONT contain 'sec',
'sig' or 'del'.
2 sec
2 sig Note there are several more possible values that
turn up in B,
3 sec do I need to let you have all of these too?
3 van
3 sec
3 dup
4 sig
4 man
7 sig

  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 26
Default Formula for multiple countifs

That works perfectly Jacob, thankyou ever so much.

"Jacob Skaria" wrote:

Try

'1st
=SUMPRODUCT((A1:A100=1)*(B1:B100={"sec","sig","del "}))

'and 2nd
=SUMPRODUCT((A1:A1001)*(A1:A100<=4)*
(ISNA(MATCH(B1:B100,{"sec","sig","del"},0))))

--
Jacob


"J.Scargill" wrote:

Hi,
I would really appreciate anybodys expertise with the following 2 formulas;
I have a worksheet that looks a bit like this - (A is days taken to deliver
- B is method for delivery)

A B
1 sec *I need to be able to count the number of cells in A
that contain
1 sig a '1' but only if they have either 'sec','sig' or
'del' in column B.
1 sec
1 man **Then I need to count the number of cells in A that
are greater 1 del or equal to '4' but DONT contain 'sec',
'sig' or 'del'.
2 sec
2 sig Note there are several more possible values that
turn up in B,
3 sec do I need to let you have all of these too?
3 van
3 sec
3 dup
4 sig
4 man
7 sig

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
Multiple CountIfs skyflier Excel Worksheet Functions 7 June 6th 09 12:33 PM
countifs with multiple dates majestyk Excel Worksheet Functions 2 February 10th 09 07:31 PM
Countifs and multiple columns... ajayb Excel Worksheet Functions 1 June 9th 06 03:29 PM
Multiple countifs ozcank Excel Worksheet Functions 2 November 14th 05 10:36 AM
COUNTIFs with multiple criteria Cene K Excel Discussion (Misc queries) 5 October 28th 05 10:43 PM


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