>Thank you. This will be a challenge for me to create such a stored procedure. I am sure it is not that complicated but I have created only very simple stored procedures. But maybe it is time to learn.
>
If the re-calculation algorithm is simple enough, I suggest to go with James' idea.
If it's not broken, fix it until it is.
My Blog