Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 9
Default Count occurance of multiple text criteria

Im using the formula

=SUM(LEN(B2:B955)-LEN(SUBSTITUTE(B2:B955,"Pension","")))/LEN("Pension")

This works fine to count the number of occurances for the word Pension but
Im stuck when trying to count using multiple criteria eg the the Pension and
the word Scheme.

Any help is greatly appreciated.

Sam.D

  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,520
Default Count occurance of multiple text criteria

Try

=SUM(COUNTIF(B2:B955,{"*Pension*","*Scheme*"}))

OR for whole cell match
=SUM(COUNTIF(B2:B955,{"Pension","Scheme"}))


--
Jacob


"Sam.D" wrote:

Im using the formula

=SUM(LEN(B2:B955)-LEN(SUBSTITUTE(B2:B955,"Pension","")))/LEN("Pension")

This works fine to count the number of occurances for the word Pension but
Im stuck when trying to count using multiple criteria eg the the Pension and
the word Scheme.

Any help is greatly appreciated.

Sam.D

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 9
Default Count occurance of multiple text criteria

Thanks, works great, huge help.

Cheers

Sam.D

"Jacob Skaria" wrote:

Try

=SUM(COUNTIF(B2:B955,{"*Pension*","*Scheme*"}))

OR for whole cell match
=SUM(COUNTIF(B2:B955,{"Pension","Scheme"}))


--
Jacob


"Sam.D" wrote:

Im using the formula

=SUM(LEN(B2:B955)-LEN(SUBSTITUTE(B2:B955,"Pension","")))/LEN("Pension")

This works fine to count the number of occurances for the word Pension but
Im stuck when trying to count using multiple criteria eg the the Pension and
the word Scheme.

Any help is greatly appreciated.

Sam.D

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 text occurance in range Stehy Excel Worksheet Functions 3 January 10th 10 10:55 PM
Count first occurance of text Chad Wodskow Excel Worksheet Functions 6 November 15th 09 10:22 AM
count using multiple criteria including text strings se7098 Excel Worksheet Functions 13 November 10th 08 09:40 PM
Count occurance of a leter in a text string justaman Excel Worksheet Functions 3 October 11th 08 04:51 AM
Count Occurance of Text/Word in a Range JPH Excel Discussion (Misc queries) 1 October 25th 07 05:02 PM


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