yogesh_pandey (10/6/2010)
Thank you for the reply. But the cur balance is in one table and the transaction is in another. I would have to use cur balance and remember the previous cur balance to calculate cur_bal for the previous transaction as I go up the list. I don't know if i make any sense. Please let me know.
the concept is still the same.; it's still a running total type of situation.
you join the main table to the transaction table to get the starting row and all the child rows. those two tables joined together are a query(just like the example data i posted);
then you can join them together, offset by a row_number() function.
without you providing the actual CREATE TABLE definitions and some sample data in a consumable format, like i posted, all i can do is offer concepts on how to tackle the issue.
or of course you could help us help you....
Lowell