Forum Discussion
Need to Sum from cell which the value comes from formula
Hi Guys!
I need help to sum my table. In case, I need to sum range which contains formulas (If) such as:
in Cell A1 100; A2 200
Then in B1 I put formula,=IF(A1=100;"1";"2")
B2 =IF(A1=100;"1";"2")
so the value out is 1 and 2, then I need to sum this value, I have a thousand ranges.
I attach here, the range is colored yellow, please help me, really need to fix this problem :(
Hi Sandi,
In your yellow zone which you try to sum you have text only which is generated by formulas like
=IF(RIGHT([@Tarif],1)="T","1","")
SUM() ignores any text and returns zero since you have no one number in the range. You may update your formulas to return numbers instead of text, like
=IF(RIGHT([@Tarif],1)="T",1,"")
or to sum all cells which have text string "1" use
=SUMPRODUCT(--([MPB]="1"))
Please see attached
Hi Sandi,
Do you really need text value as result of your formula? SUM ignores text, to sum you shall convert it back to numbers somehow. Easier to generate numbers from very beginning, like
=(A1=100)+1
in B1. With IF
=IF(A1=100;1;2)
- sandi saputraCopper ContributorHi Sergei,
Thank you for your response, I just came back to office. In case, in cell A1 is validated number, so if it doesn't mind you, would you like to open my file and see the cells which I need to sum.
Thank you so much, very need help :)Hi Sandi,
In your yellow zone which you try to sum you have text only which is generated by formulas like
=IF(RIGHT([@Tarif],1)="T","1","")
SUM() ignores any text and returns zero since you have no one number in the range. You may update your formulas to return numbers instead of text, like
=IF(RIGHT([@Tarif],1)="T",1,"")
or to sum all cells which have text string "1" use
=SUMPRODUCT(--([MPB]="1"))
Please see attached