• I can help you to write the update statement. But I would like to know why are you doing this? This will help you with 3 days but what happens with a whole month? or a whole year? Why do you have this table design?

    You shouldn't store values that way, to show the results in a report would be ok (even if some people say it should be done in the front end).

    Please, review the requirements and then confirm you need to do this.

    Luis C.
    General Disclaimer:
    Are you seriously taking the advice and code from someone from the internet without testing it? Do you at least understand it? Or can it easily kill your server?

    How to post data/code on a forum to get the best help: Option 1 / Option 2