forked from rDrama/rDrama
8 lines
217 B
MySQL
8 lines
217 B
MySQL
|
create function public.lifetime_donated(public.users) returns integer
|
||
|
language sql immutable strict
|
||
|
as $_$
|
||
|
select sum(amount)
|
||
|
from transactions
|
||
|
where transactions.email = $1.email
|
||
|
$_$;
|