recordset programming problem!

S

Sam Hung

Hi All,

I have another database table like this:

Month Prod_No Open_Bal Input Output Clos_Bal
1 1111 0 300 3 297
1 2222 0 52 5 47
1 5555 0 78 40 38
2 1111 297 0 197 100
2 5555 38 20 16 42
3 2222 47 12 35 24
As you check out the column(Open_Bal), the last three
records are copied by the first three records in the column
(Clos_Bal - 1111[297],2222[47],5555[38]). It bases on the
condition whether the next '1111' is found somewhere
through looping(Do Loop) as the pointer is at the first
record '1111', then the data of the column(Clos_Bal) will
copy to the next found record '1111'(Open_Bal).
Do I have to use recordset programming method to modify
Open_Bal in this recordset, or use two 'for loops' to
search same prod_no, or what should I do?

Please help,
Thanks,
Sam.
 
Top