Hi Sergey,
is that one group or four separate groups?
The Amount Received is not totalled for every detail line, just for each receipt. so in the example I gave the total is 560 = 120 + 200 + 240, but the Report is totalling like this 120 + 120 + 200 + 240. In VFP I would have created two report variables, one storing the Receipt number and another adding the Amount Received only when the Receipt number changed.
I have actually changed the data design so that his is no longer an issue, but would still like to know how to do this in the event it arises again.
>You should group on Agent, Policy, Policy Year and maybe Receipt.
>
>You'll have to tell us how to get correct sub-total on Amount Received. IOW, what determines if amount from a particular record should be included in the subtotal.
>
>>
>>I'm trying to define a report which will display data like this:
>>
>>
Agent: Fred
>>
>>Policy # Amount Received Policy Year Commission
>>12345 120 1 1.00
>> 2 0.50
>>54321 200 1 2.00
>>09876 240 1 3.00
>> ______ _______
>> 560 6.50
>>
>>The data that is used to drive the report is similar to this:
>>
>>
>>Agent Policy AmtReceived PolicyYear Commission Receipt
>>Fred 12345 120 1 1.00 001
>>Fred 12345 120 2 0.50 001
>>Fred 54321 200 1 2.00 002
>>Fred 12345 240 1 3.00 003
>>
>>A receipt's amount can be split into multiple records.
>>
>>So I need a group on Agent and I believe a group on Receipt. How do I get the sub-totalling on Amount Received to give me 560 rather than doubling the 120?