This is a migrated thread and some comments may be shown as answers.

Grouped sums subtractions

1 Answer 140 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Nik
Top achievements
Rank 1
Nik asked on 13 Oct 2008, 01:20 AM

Hi all,

 

I’m testing telerik reporting and I’m facing the following problem in my report.  Data is grouped by a certain value, and details have grouped sums (several of them) with an expression =Sum(IIf(Fields.digits >=4, Fields.debit,0))(just the field is changed according the data column) which work fine. Now I need to compare the values and get the difference of them.

So basically,IF =Sum(IIf(Fields.digits >=4, Fields.debit,0))   >    =Sum(IIf(Fields.digits >=4, Fields.credit,0)) then ( =Sum(IIf(Fields.digits >=4, Fields.debit,0)))  -  (=Sum(IIf(Fields.digits >=4, Fields.credit,0))) and the value should be displayed into another grouped summary field , say, Balance.

I’ve tried anything I could’ve think of unfortunately without any success, so any help would be appreciated.

Thanks,

Nik

1 Answer, 1 is accepted

Sort by
0
fullstop
Top achievements
Rank 1
answered on 14 Oct 2008, 01:57 PM
I actually did this with an Expression


= IIf(Sum(IIf(Fields.digits >=4, Fields.credit,0)) > Sum(IIf(Fields.digits >=4, Fields.debit,0)),Sum(IIf(Fields.digits >=4, Fields.credit,0)) - Sum(IIf(Fields.digits >=4, Fields.debit,0)),0)

the expression is huge, but works

Nik
Tags
General Discussions
Asked by
Nik
Top achievements
Rank 1
Answers by
fullstop
Top achievements
Rank 1
Share this question
or