MoePolygon Fees dex
    Updated 2022-07-08
    select
    date_trunc('day', block_timestamp)::date as date,
    ADDRESS_NAME,
    sum(tx_FEE) fees,
    sum(fees)over( partition by ADDRESS_NAME order by date rows between unbounded preceding and current row ) as cum_fees
    from polygon.core.fact_transactions t,polygon.core.dim_labels l
    where t.TO_ADDRESS = l.address
    and
    BLOCK_TIMESTAMP:: date >= '2022-07-01'
    and LABEL_TYPE = 'dex'
    group by 1,2 order by 1
    Run a query to Download Data