UPDATE prizes pr
SET won_count = (
    SELECT COUNT(*)
    FROM plays p
    WHERE p.prize_id = pr.id
      AND p.result = 'win'
);
