0

Assume I have the following data:

enter image description here

I want to do a calculation based on each currency and amount. Something like:

enter image description here

So money in (for USD) will be the sum of column H where the amount is positive, and the currency is USD. Money out (for USD) will be the sum of column H where the amount is negative, and the currency is USD.

How to calculate this? I'm thinking of using SUMIFS, but I always get Err:502. My formula is :

=SUMIFS($H$2:$H$65440, G2, "USD", H2, ">0")

1 Answer 1

0

From the official Libreoffice documentation

Func_Range and Range1, Range2... must have the same size, otherwise the function returns err:502 - Invalid argument.

So you must use ranges in your conditions, and your formula should be

=SUMIFS($H$2:$H$65440, $G$2:$G$65440, "USD", $H$2:$H$65440, ">0")

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .