Hello, I am wondering if it is possible to use the sumproduct or sumif
function (or some other function, or perhaps the use of array
formulas, or some other trick) in order to do the following.
For example, for:
Column A ColumnB
apple 10
orange 12
tomato 23
blueberry 18
etc etc
How can I say to excel: "sum corresponding data in column B, If column
A has: 'apple' or 'orange' or any of about 15 other items." In
essence, I need to do an OR query with many potential matches. Is
there a way to do this? Can I refer to a range of items within the
Sumif or sumproduct or vlookup formula?
I originally tried using a long sumproduct formula, but it got to be
incredibly long, and didn't seem to work....
Note that this is a formula that I will be using over and over to
extract data from a report, based on the medical service categories of
numerous states, and grouped under numerous dates.
FYI, the end result will look something like this for each State, as
will be pulled from a daily (dynamic) report:
Day 1 Day 2 Etc......
Medical Formula Formula
Surgical Formula Formula
Neonatal Formula Formula
Etc
Thanks for any thoughts.....
T. Valko - 26 Feb 2008 03:48 GMT
Try this:
List your criteria in a range of cells:
F1 = apple
F2 = orange
Then:
=SUMPRODUCT(--(ISNUMBER(MATCH(A1:A4,F1:F2,0))),B1:B4)

Signature
Biff
Microsoft Excel MVP
> Hello, I am wondering if it is possible to use the sumproduct or sumif
> function (or some other function, or perhaps the use of array
[quoted text clipped - 32 lines]
>
> Thanks for any thoughts.....
Eli - 26 Feb 2008 16:53 GMT
Hello Mike,
What you are describing is a typical application that people try to do in
Excel but should be done with other tools.
You have a dynamic Excel file which grows on a daily basis and you need to
get aggregated reports and analysis based on criteria which are also
changing.
What you really need is database functionality over your Excel file.
To make your life easier, you could use Business Intelligence tool that will
use the Excel data as its input and will relieve you from the tedious and
repetitive work of updating ranges and copying formulas to newly added rows
or columns.
Such a tool is Prism (www.sisense.com) which handles the Excel files as a
database, thus enables you the creation of complex views as well as visual
Dashboards just by drag-n-drop operations. This will not only improve the
handling efficiency of your Excel files but will open new insights into your
data.
Regards
Eli
> Hello, I am wondering if it is possible to use the sumproduct or sumif
> function (or some other function, or perhaps the use of array
[quoted text clipped - 32 lines]
>
> Thanks for any thoughts.....
T. Valko - 26 Feb 2008 18:14 GMT
LOL!

Signature
Biff
Microsoft Excel MVP
> Hello Mike,
> What you are describing is a typical application that people try to do in
[quoted text clipped - 57 lines]
>>
>> Thanks for any thoughts.....
Don Guillett - 26 Feb 2008 18:45 GMT
Agreed

Signature
Don Guillett
Microsoft MVP Excel
SalesAid Software
dguillett1@austin.rr.com
> LOL!
>
[quoted text clipped - 59 lines]
>>>
>>> Thanks for any thoughts.....
Herbert Seidenberg - 26 Feb 2008 17:12 GMT
Six more ways:
http://www.freefilehosting.net/download/3cica