i have table for stock control and i want the balance updated every row
i have table inside for with the following database items
i want that this balance update with every transaction for every row
for example second row should be
third row should be
and so on
pls help me
And what is the event to update the rows? What values do you want to updated?
btw. You should rethink your datamodel, as at least one column is redundant, as its value can be derived from the other values.
I still don't understand what should exactly happen. There is some event, and then? Is a new record inserted in your table? Or have some of the rows to be updated? And what is your sort-criteria? Do you have some date-column or some transaction-id?
this is database items with these numbers
when i insert new row it should give me the result of calculation of first row then balance = the total of first row that is mean balance will be like that
and when i insert or update the item add = 20
tjhat is mean total = 220
and the new row will be
and so on
Edited by: yasser_egypt on Nov 12, 2012 12:05 AM