cypherThorra-LUNA-UST - fees generated
    Updated 2022-04-21
    --iff(charindex('-', pool_name) = 0, pool_name, LEFT(pool_name, CHARINDEX('-', pool_name) - 1))
    select
    iff(charindex('-', pool_name) = 0, pool_name, LEFT(pool_name, CHARINDEX('-', pool_name) - 1)) as pool,
    sum(total_swap_fees_usd) as total_swap_fees
    from thorchain.daily_pool_stats
    where day >= '2022-3-25'
    group by pool
    Run a query to Download Data