>Michel, Sorry I am not providing any help with your question, but I would change the whole approach, after all why do you update fields that can be calculated when required? You can easily create a view with this information without the massive updates with values that are derived from other tables/fields.
This is a process to fix values in an existing table.
The live maintenance of those fields is done whenever a record is being updated.