PC Review


Reply
Thread Tools Rate Thread

COUNTIFS-Want to remove several words in one column w/multi criter

 
 
Mmichole
Guest
Posts: n/a
 
      21st Feb 2009
I am trying to use the COUNTIFS function w/multiple criteria in an Excel 2007
workbook to count sales for reps in a summary tab but want to remove 3
different words in one column from the count. I've tried several scenarios
and continue to get an error message or 0 results. Below is an example of the
data I'm using and the function that went awry. Please help! Thanks in
advance.

Clmn N Clmn R Clmn S Clmn T Clmn U
CREATE DTE SALESID CHK IN OPID JOB REASON
1/23/2009 40974 ARR 1PQH Install NON PAY RESTART
1/23/2009 16029 LOC L24M Install TRANSFER
1/23/2009 16029 Install TRANSFER
1/23/2009 40904 Install TRANSFER
1/26/2009 40981 Upgrade CUSTOMR CONTACT


Function that worked w/1 word:=COUNTIFS('Video Detail'!$N:$N, 'Feb Video
Sales'!D$3,'Video Detail'!$U:$U,"<>TRANSFER",'Video Detail'!$R:$R, 'Feb Video
Sales'!$B$43)

Function that didn't work w/ all words to exclude:=COUNTIFS('Video
Detail'!$N:$N, 'Feb Video Sales'!D$3,'Video Detail'!$U:$U,<>{"TRANSFER","NON
PAY RESTART”,”NON-PAY RESTART”},'Video Detail'!$R:$R, 'Feb Video
Sales'!$B$43)


 
Reply With Quote
 
 
 
 
T. Valko
Guest
Posts: n/a
 
      21st Feb 2009
COUNTIFS doesn't easily handle multiple array constants. It really depends
on what you're trying to do.

Use SUMPRODUCT instead.

Use cells to hold your criteria:

H1 = TRANSFER
H2 = NON PAY RESTART
H3 = NON-PAY RESTART

Then use this general syntax:

=SUMPRODUCT(--(A1:A10=D3),--(ISNA(MATCH(B1:B10,H1:H3,0))),--(C1:C10=B43))


--
Biff
Microsoft Excel MVP


"Mmichole" <(E-Mail Removed)> wrote in message
news:5C65A6AD-5A64-4255-844E-(E-Mail Removed)...
>I am trying to use the COUNTIFS function w/multiple criteria in an Excel
>2007
> workbook to count sales for reps in a summary tab but want to remove 3
> different words in one column from the count. I've tried several scenarios
> and continue to get an error message or 0 results. Below is an example of
> the
> data I'm using and the function that went awry. Please help! Thanks in
> advance.
>
> Clmn N Clmn R Clmn S Clmn T Clmn U
> CREATE DTE SALESID CHK IN OPID JOB REASON
> 1/23/2009 40974 ARR 1PQH Install NON PAY RESTART
> 1/23/2009 16029 LOC L24M Install TRANSFER
> 1/23/2009 16029 Install TRANSFER
> 1/23/2009 40904 Install TRANSFER
> 1/26/2009 40981 Upgrade CUSTOMR CONTACT
>
>
> Function that worked w/1 word:=COUNTIFS('Video Detail'!$N:$N, 'Feb Video
> Sales'!D$3,'Video Detail'!$U:$U,"<>TRANSFER",'Video Detail'!$R:$R, 'Feb
> Video
> Sales'!$B$43)
>
> Function that didn't work w/ all words to exclude:=COUNTIFS('Video
> Detail'!$N:$N, 'Feb Video Sales'!D$3,'Video
> Detail'!$U:$U,<>{"TRANSFER","NON
> PAY RESTART","NON-PAY RESTART"},'Video Detail'!$R:$R, 'Feb Video
> Sales'!$B$43)
>
>



 
Reply With Quote
 
Ron Rosenfeld
Guest
Posts: n/a
 
      21st Feb 2009
On Sat, 21 Feb 2009 10:35:01 -0800, Mmichole
<(E-Mail Removed)> wrote:

>I am trying to use the COUNTIFS function w/multiple criteria in an Excel 2007
>workbook to count sales for reps in a summary tab but want to remove 3
>different words in one column from the count. I've tried several scenarios
>and continue to get an error message or 0 results. Below is an example of the
>data I'm using and the function that went awry. Please help! Thanks in
>advance.
>
>Clmn N Clmn R Clmn S Clmn T Clmn U
>CREATE DTE SALESID CHK IN OPID JOB REASON
>1/23/2009 40974 ARR 1PQH Install NON PAY RESTART
>1/23/2009 16029 LOC L24M Install TRANSFER
>1/23/2009 16029 Install TRANSFER
>1/23/2009 40904 Install TRANSFER
>1/26/2009 40981 Upgrade CUSTOMR CONTACT
>
>
>Function that worked w/1 word:=COUNTIFS('Video Detail'!$N:$N, 'Feb Video
>Sales'!D$3,'Video Detail'!$U:$U,"<>TRANSFER",'Video Detail'!$R:$R, 'Feb Video
>Sales'!$B$43)
>
>Function that didn't work w/ all words to exclude:=COUNTIFS('Video
>Detail'!$N:$N, 'Feb Video Sales'!D$3,'Video Detail'!$U:$U,<>{"TRANSFER","NON
>PAY RESTART,NON-PAY RESTART},'Video Detail'!$R:$R, 'Feb Video
>Sales'!$B$43)
>


Here's one that seems to work without all the sheet references. You should be
able to adapt it.

Note that if you are EXCLUDING certain fields, you should also exclude BLANKS
and the LABEL in the first column:

=COUNTIFS(U:U,"<>JOB",U:U,"<>",U:U,"<>TRANSFER",U:U,"<>NON PAY RESTART")

--ron
 
Reply With Quote
 
Shane Devenshire
Guest
Posts: n/a
 
      21st Feb 2009
Hi,

You can use countifs for this but the setup would look like this instead of
what you are trying:

=COUNTIFS(A:A, F1,C:C,"<>TRANSFER",C:C,"<>Test",D, G1)

Note I changed the references so I could test more easily. I would also
modify this to

=COUNTIFS(A:A, F1,C:C,"<>"&H1,C:C,"<>"&H2,D, G1)

where H1 and H2 contain two of your conditions, then just add the third
condition.


--
If this helps, please click the Yes button

Cheers,
Shane Devenshire


"Mmichole" wrote:

> I am trying to use the COUNTIFS function w/multiple criteria in an Excel 2007
> workbook to count sales for reps in a summary tab but want to remove 3
> different words in one column from the count. I've tried several scenarios
> and continue to get an error message or 0 results. Below is an example of the
> data I'm using and the function that went awry. Please help! Thanks in
> advance.
>
> Clmn N Clmn R Clmn S Clmn T Clmn U
> CREATE DTE SALESID CHK IN OPID JOB REASON
> 1/23/2009 40974 ARR 1PQH Install NON PAY RESTART
> 1/23/2009 16029 LOC L24M Install TRANSFER
> 1/23/2009 16029 Install TRANSFER
> 1/23/2009 40904 Install TRANSFER
> 1/26/2009 40981 Upgrade CUSTOMR CONTACT
>
>
> Function that worked w/1 word:=COUNTIFS('Video Detail'!$N:$N, 'Feb Video
> Sales'!D$3,'Video Detail'!$U:$U,"<>TRANSFER",'Video Detail'!$R:$R, 'Feb Video
> Sales'!$B$43)
>
> Function that didn't work w/ all words to exclude:=COUNTIFS('Video
> Detail'!$N:$N, 'Feb Video Sales'!D$3,'Video Detail'!$U:$U,<>{"TRANSFER","NON
> PAY RESTART”,”NON-PAY RESTART”},'Video Detail'!$R:$R, 'Feb Video
> Sales'!$B$43)
>
>

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Countifs to Sumproduct for 2003 -> was Simple Countifs.. from Fr Steve Microsoft Excel Worksheet Functions 2 4th Jan 2009 05:36 PM
How can I place a multi column sub rpt in a multi column report? =?Utf-8?B?R09T?= Microsoft Access Reports 5 25th Aug 2006 08:18 PM
how do i insert words into a column without erasing the words =?Utf-8?B?c29jY2VyNTU4NQ==?= Microsoft Excel Misc 0 8th Jun 2005 11:06 PM
Extract values from a multi-select multi-column list-box Peter Microsoft Excel Programming 5 28th Sep 2003 04:04 PM
Searching for a words in a column from a list of words. Scott Microsoft Excel Programming 5 15th Aug 2003 02:40 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 12:05 PM.