1587. Bank Account Summary II
select (select name from Users u where u.account=t.account) as name, sum(t.amount) as balance from Transactions t group by t.account having sum(t.amount)>10000;