Hi,
I have a list of products in Excel with data like Product Number, Product Name, Quantity (Income/Outcome), Date, Invoice number, etc. but the first three are relevant to my case.
The table looks like this:
The positive values are Income and the negative are the Outcome of the item.
Now I would like to sum in one column Income values, and in the other one Outcome values.
For example:
I thought using formula =SUMIF($A$2:$A$218;!A2;$C$2:$C$222) and this works fine if I want to count positive and negative values together, but I don't know how to put in this formula a criteria for summing only negative or positive values as there is already a criteria that it equals "A2" .
Thanks for any help.
I have a list of products in Excel with data like Product Number, Product Name, Quantity (Income/Outcome), Date, Invoice number, etc. but the first three are relevant to my case.
The table looks like this:
PN | Product name | Qty (Income/Outcome) | ... |
---|---|---|---|
PN1 | Product1 | -6 | ... |
PN2 | Product2 | -2 | ... |
PN3 | Product3 | -6 | ... |
PN4 | Product4 | -6 | ... |
PN5 | Product5 | -6 | ... |
PN6 | Product6 | -6 | ... |
PN7 | Product7 | -20 | ... |
PN5 | Product5 | 570 | ... |
PN1 | Product1 | -7 | ... |
PN3 | Product3 | -7 | ... |
PN4 | Product4 | -7 | ... |
PN5 | Product5 | -7 | ... |
PN6 | Product6 | -7 | ... |
PN7 | Product7 | 54 | ... |
... | .... | ... | ... |
The positive values are Income and the negative are the Outcome of the item.
Now I would like to sum in one column Income values, and in the other one Outcome values.
For example:
PN | Income | Outcome |
---|---|---|
PN1 | 13 | |
PN2 | 2 | |
PN3 | -13 | |
PN4 | -13 | |
PN5 | 570 | 13 |
PN6 | 13 | |
PN7 | 54 | 20 |
I thought using formula =SUMIF($A$2:$A$218;!A2;$C$2:$C$222) and this works fine if I want to count positive and negative values together, but I don't know how to put in this formula a criteria for summing only negative or positive values as there is already a criteria that it equals "A2" .
Thanks for any help.