7 Replies Latest reply: Feb 23, 2016 12:51 PM by Sunny Talwar

# Sum a value by another value.

Hey guys. My Expression looks like this:

Sum(total([Bokfört belopp] * [Andel av kapital]))

Obviously it doesn't match my demands and i was wondering if you could help me.

I want to sum "bokfört belopp" by Customernumber and customerID and multiple it with "andel av kapital"

how do i move on from here?

• ###### Re: Sum a value by another value.

sorry autocorrect, i ment account number not customer number

and i want a total sum of "bokfört belopp" from the account number based on the Customer ID and multiple it with "andel av kapital"

Kind Regards

• ###### Re: Sum a value by another value.

Are you doing this in a chart or text box object? Not sure I understand what exactly you are trying to do. May be you can share a sample with us?

• ###### Re: Sum a value by another value.

Oh yes, sorry. I'm doing a pivot table in a chart.

I cant share it in a picture because the info in this applikation is classified.

"Bokfört belopp" - Its basically the amount of money based on the Account Number and CustomerID

"Antal av kapital" - Is a number that counts how many accounts there is per CustomerID based on Account number.

And i want a total sum of "bokfört belopp" from the account number based on the Customer ID and multiple it with "andel av kapital"

Hope this helps.

Kind Regards.

• ###### Re: Sum a value by another value.

May be this:

Sum(Total <[Customer ID]> [Bokfört belopp]) * Sum([Andel av kapital])

• ###### Re: Sum a value by another value.

Hey Sunny. Thanks for the reply it worked perfectly. I just changed the Customer ID for the Account Number.

But i got one more question.

My expression currently looks like this:
Sum({<[Kontonummer]>} [Bokfört belopp]) * Sum([Andel av kapital]) - '919650'

And i dont want to show anything thats under the value 0 when using this expression. Got a solution for this?

PS. The Supress Zero-Values button is allready checked in.

Kind Regards

D.Z

• ###### Re: Sum a value by another value.

Sorry, wrong from me again.

I don't want to show anything ABOVE the value '91950'. Everything under that value has to be seen.

• ###### Re: Sum a value by another value.

May be this:

If(Sum({<[Kontonummer]>} [Bokfört belopp]) * Sum([Andel av kapital]) - '919650' > 0, Sum({<[Kontonummer]>} [Bokfört belopp]) * Sum([Andel av kapital]) - '919650')