Hi to all,
we have a relation order_to_order_lines in a form of name Orders wich contains the tabpanel of the relation above.
The amount_field of the order is placed in the form Orders, and after a new record in the tabpanel we need to use “databaseManeger.recalculate”, in order to update the amount of the order. But it is too much expensive (many minutes the first time we insert th first record in the tabpanel).
Any idea?
Tanks in advance.
Gianni Pinna.
How many related records are there to recalculate? Surely not that many for the “minutes” that you mention.
Have you tried doing a recalculate on just the one record rather than the whole foundset (of the relation)?
Is the amount that you talk about the sum of all the order lines = the aggregate sum of each order line? And do you use the aggregate capability?
Hi Thomas,
tank You very much for Your answer.
- ) You wrote
Have you tried doing a recalculate on just the one record rather than the whole foundset (of the relation)?
No I didn’ t but I’ll try.IT, OF SURE WIL BE BETTER than the command wich, in the while i gave with a good effect:
order_to_lines_order.loadRecords();
2.) Moreover, Thomas, You wrote:
Is the amount that you talk about the sum of all the order lines = the aggregate sum of each order line? And do you use the aggregate capability?
Yes
Yes.
Many Tanks again, Thomas.
Hope fine for You.
Sincerly.
Gianni Pinna