Bug [#45093187] Juhan has too many columns

Cleans up the DB (removes duplicates and such) then adds an index on
(assignment_id, beginning_of_week) so that no duplicate can be inserted
in the future.