**# EXAMPLE SQL CTEs:**
WITH cte_transations AS (SELECT
-- the result set of a query which exists temporarily and for use only
-- within the context of a larger query.
-- the result of a CTE is not stored and exists only for the duration of the query.
account_id,
sum(amount),
sum(balance)
FROM bank.trans
GROUP BY 1),
cte_account AS (SELECT
*
FROM cte_transactions ct
JOIN bank.account a
USING (account_id))