forked from github/server
7 lines
247 B
MySQL
7 lines
247 B
MySQL
|
select u.id ID, left(concat(firstname,' ',lastname, ' <',email,'>'),43) Name, sum(t.balance) Kontostand
|
||
|
from users u, transactions t
|
||
|
where u.id=t.user
|
||
|
and u.status!='CONFIRMED'
|
||
|
GROUP BY u.id
|
||
|
HAVING SUM(t.balance)<2.5;
|