Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Can not get the correct Grand Total
Message
From
13/04/1998 00:51:16
 
General information
Forum:
Visual FoxPro
Category:
Reports & Report designer
Miscellaneous
Thread ID:
00091431
Message ID:
00091441
Views:
27
>>>I guess you have the wrong file or alias name when the report form executes. Because based on your latest data, the SUM is 1200.
>>>Try to check the alias at the deactivate method of the form.
>>>Another possible solution, just group the SELECT by name to get the 3 rows only, bec. as I understand, you're just trying to get the unique rows right?

The following data is the result of SQL from two tables (customer table and payment table) where each customer can have partial payments. e.g: John has a credit limit of 100 and he's paid three times (5, 10 and 30). I want the Grand Total to show only the actual total of credit limit of each customer (John=100, Marry=300, Tony = 300) which comes to 700. But the total on the summary band always shows 1200. How can I get the sum of 700 of 3 customers' credit limits ?

Name Limit Payment
John 100 5
John 100 10
John 100 30
Marry 300 20
Mary 300 50
Tony 300 80

Thanks a lot for your help,
Regards,
Andi Hidajat
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform