Assignment of a total to details [message #68134] |
Mon, 15 August 2005 15:47 |
Eclipse User |
|
|
|
Originally posted by: sieghard.dippelreiter.promac.at
Hi all,
we have to produce a report, in which a total has to be split into parts,
which are determinded by data stored in multiple entries in a different
table.
E.g. payments from customers are stored in a table "customer accounts",
the amounts of the invoices are stored in an table "invoices":
A customer has to pay three invoices
Invoice1 50,--
Invoice2 200,--
Invoice3 100,--
The customer pays 300,-- and we have to report the status, so we want to
do: payment 300,-- less invoice1 remains 250,-- and then 250,-- less
200,-- remains 50,-- and then 50,-- less 100,--: the customer stll owes
50,--.
Should be easy - BUT
Our problem is, that we cannot save the remaining amount (250,--) from
invoice1 for dealing with invoice2, either we get 300,-- from the customer
table or we get 0/zero when we define a special variable, eg "surplus" to
bridge from invoice1 to invoice2.
Thanks for advice.
regards
Sieghard
|
|
|
Powered by
FUDForum. Page generated in 0.02954 seconds