scottincryptoMaticX Balancer LP Token TotalSupply
    Updated 2022-09-28
    with dates as (
    select
    date_day as block_day
    from ethereum.core.dim_dates
    where date_day > '2022-04-20'
    and date_day <= current_date
    )

    , mints as (
    select
    date_trunc('day', block_timestamp) as block_day
    -- , contract_address
    , sum(raw_amount) / 1e18 as mint_amount
    from polygon.core.fact_token_transfers
    where 1=1
    and contract_address in (

    '0xc17636e36398602dd37bb5d1b3a9008c7629005f' --Balancer Matic/MaticX
    )
    and from_address = '0x0000000000000000000000000000000000000000'
    and block_timestamp > '2022-04-20'
    group by 1
    )

    , burns as (
    select
    date_trunc('day', block_timestamp) as block_day
    -- , contract_address
    , sum(raw_amount) / 1e18 as burn_amount
    from polygon.core.fact_token_transfers
    where 1=1
    and contract_address in (

    '0xc17636e36398602dd37bb5d1b3a9008c7629005f' --Balancer Matic/MaticX
    )
    and to_address = '0x0000000000000000000000000000000000000000'
    Run a query to Download Data