alter table public.users
    add column is_banned       boolean default false,
    add column approx_ban_date timestamp with time zone;

update public.users
set is_banned       = true,
    approx_ban_date = now()
from (select distinct user_id
      from scores
      where is_banned = true) banned_users
where public.users.user_id = banned_users.user_id;
