Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Sum of a field for a specific value in a variable

Sum({<[Category] = {$(Graph1-Group-Value)}>}Budget)

     I want to find the sum of Budget, when Category matches a value specified in a variable, where category is another field in the dataset with Budget.

Here '$(Graph1-Group-Value)' is defined as below

            if($(Graph1-Group1) = 'CML & Synd. Loans - Avg','CML & Synd. Loans - Avg','No Value')

With the above script, the value is not captured

1 Solution

Accepted Solutions
sunny_talwar

May be try this:

Sum({<[Category] = {'$(=$(Graph1-Group-Value))'}>}Budget)

or


Sum({<[Category] = {'$(=Graph1-Group-Value)'}>}Budget)

View solution in original post

2 Replies
sunny_talwar

May be try this:

Sum({<[Category] = {'$(=$(Graph1-Group-Value))'}>}Budget)

or


Sum({<[Category] = {'$(=Graph1-Group-Value)'}>}Budget)

sunny_talwar

Or you can check it directly like this:

Sum({<[Category] = {"$(=If($(Graph1-Group1) = 'CML & Synd. Loans - Avg', 'CML & Synd. Loans - Avg', 'No Value'))"}>}Budget)