# Help me ! I want to create two or more functions work in one cell.

P

#### peter via OfficeKB.com

I want to create two or more functions to works in one cell, respectively:

IF(AND(B5=B21,A5=A22),SUM(C5),"") and IF(AND(B5=B21,A6=A22),SUM(C6),"")
Independently they work but when I’m ordering one by one in sell appears
FEALS.
I tried to apply before OR , IF(OR …. , but something’s wrong.

J

#### JE McGimpsey

One way:

=(B5=B21)*((A5=A22)*C5 + (A6=A22)*C6)

P

#### peter dimitrakis via OfficeKB.com

I’m afraid but it doesn’t work. I want to execute one of that two results,
or C5 or C6.

J

#### JE McGimpsey

Could you give specific examples of what "doesn't work"?

What if A5=A22 and A6=A22?

P

#### peter dimitrakis via OfficeKB.com

A5 AND A6 are the names of products. B5 is data, C4 and C5 are quantity of
the same products. This is the part of the consignation table. This is the
first table.

The second table:
A22 is the name of the product, B21 is data and I aply formula in B22 (is
quantity of first product on first day of the second table).
I want to compare the names and check data and if they are the same as in
second table to aply quantity from first to second table. If not the same to
aply nothing. The problem is that the consignation table has two or more
products and I have to check data and then product by product ...
I hope you understend , this is very difficult for me.