Adding Columns Based on Text

R

Rich9016

Hi,
I'm not sure what to call what i'm doing, so please bear with me.

In column A, starting from cell A7, i have various text, for example
apple, orage, grape, etc. Each of these data is followed by additiona
data in the next column, B. For example, apple - new, or apple - old.
Column C will then have dollar figures relating to the prior data.

What i want to do is add up only the columns that have apple, and giv
a sum for that, then only the columns for oranges, then give a sum fo
that, and so on.

Is there a way to do this as opposed to manually adding each item?
Sorry if I'm a little vague, I'm not an excel expert by far.

If anyone can help I would greatly appreciate it.

Thank you in advance.

Ric
 
R

Rich9016

i actually thought of another question. if i were to use the formul
you gave me, is there any way i can search for cells containing th
word apple as opposed to the exact phrase being apple? in other words
if a cell contains apple total, orange total, i want to add those cell
only.

i can't use pivot tables since my data isn't properly organized
 
D

Dave Peterson

=SUMIF(A7:A100,"*apple*",C7:C100)

(and watch out for those ranges. You want both to start in row 7)
 
R

RagDyer

You could do it two ways:

Enter a particular product that you wish to lookup in D6,
And enter this formula in E6:

=SUMPRODUCT((ISNUMBER(SEARCH(D6,A7:A100)))*C7:C100)

OR
You could enter a list of products down column D, and drag down to copy
this same formula with absolute references:

=SUMPRODUCT((ISNUMBER(SEARCH(D6,$A$7:$A$100)))*$C$7:$C$100)
--

HTH,

RD
==============================================
Please keep all correspondence within the Group, so all may benefit!
==============================================


i actually thought of another question. if i were to use the formula
you gave me, is there any way i can search for cells containing the
word apple as opposed to the exact phrase being apple? in other words,
if a cell contains apple total, orange total, i want to add those cells
only.

i can't use pivot tables since my data isn't properly organized.
 
Top