A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Excel » Worksheet Functions
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Need solution for wildcard use in array



 
 
Thread Tools Display Modes
  #1  
Old April 27th, 2010, 08:08 PM posted to microsoft.public.excel.worksheet.functions
Another wildcard and array problem
external usenet poster
 
Posts: 1
Default Need solution for wildcard use in array

I need to find a solution for the following formula to be used in an Excel
worksheet in Excel 2003:

=SUM((('GCP Vendors'!L3:L999)="*Other*")*(('GCP Vendors'!O3:O999)=
"Consultation"))

I need to count the number of times a cell contains the partial string
"Other" in the L column and then sum up how many of these strings are related
to "Consultation" in the O column. I can't figure out how to substitute for
"*Other*" in an array.

Thanks,
GP
  #2  
Old April 27th, 2010, 08:40 PM posted to microsoft.public.excel.worksheet.functions
Dave Peterson
external usenet poster
 
Posts: 19,791
Default Need solution for wildcard use in array

One way is to use
=isnumber(search(...))

=SUMPRODUCT(--(ISNUMBER(SEARCH("other",'gcp vendors'!L3:L999))),
--('gcp vendors'!O3:O999="Consultation"))

Using =sumproduct() means that I don't have use ctrl-shift-enter to enter the
formula.

And I like the -- and commas syntax.

But

=SUM((ISNUMBER(SEARCH("other",'gcp vendors'!L3:L999))),
*('gcp vendors'!O3:O999="Consultation"))

will work as an array formula.

Ps. If you want to match case, then use =find() instead of =search().

Another wildcard and array problem wrote:

I need to find a solution for the following formula to be used in an Excel
worksheet in Excel 2003:

=SUM((('GCP Vendors'!L3:L999)="*Other*")*(('GCP Vendors'!O3:O999)=
"Consultation"))

I need to count the number of times a cell contains the partial string
"Other" in the L column and then sum up how many of these strings are related
to "Consultation" in the O column. I can't figure out how to substitute for
"*Other*" in an array.

Thanks,
GP


--

Dave Peterson
  #3  
Old April 27th, 2010, 08:51 PM posted to microsoft.public.excel.worksheet.functions
Tom Hutchins
external usenet poster
 
Posts: 722
Default Need solution for wildcard use in array

Try

=SUMPRODUCT(--(ISNUMBER(FIND("Other",L3:L999))),--(O3:O999="Consultation"))

Hope this helps,

Hutch

"Another wildcard and array problem" wrote:

I need to find a solution for the following formula to be used in an Excel
worksheet in Excel 2003:

=SUM((('GCP Vendors'!L3:L999)="*Other*")*(('GCP Vendors'!O3:O999)=
"Consultation"))

I need to count the number of times a cell contains the partial string
"Other" in the L column and then sum up how many of these strings are related
to "Consultation" in the O column. I can't figure out how to substitute for
"*Other*" in an array.

Thanks,
GP

 




Thread Tools
Display Modes

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

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 12:41 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.