vendettaOsmosis's daily total price of type coins Osmosis's total swap of type coins Percentage of Osmosis's total swap of type coins Osmosis's daily swap of type coins Osmosis's total price of type coins Osmosis's Daily New Trader Percentage of Osmosis's total new trader of type coins Osmosis's total new trader of type coins
    Updated 2023-02-24
    -- forked from 17ea7afe-e6e8-427b-b7db-b8d0d0bd7aea

    with meta_address AS
    (
    SELECT
    TRADER AS unique_trader
    , min(BLOCK_TIMESTAMP)::date as min_date
    FROM
    osmosis.core.fact_swaps
    WHERE
    BLOCK_TIMESTAMP::date >= '2022-12-01'
    GROUP BY
    unique_trader
    )

    SELECT
    min_date

    , count( DISTINCT unique_trader ) AS new_trader
    , count( DISTINCT os_swap.tx_id ) AS total_swap
    , CASE
    when os_tokens.project_name = 'AVAX' then 'AVAX'
    when os_tokens.project_name = 'BNB' then 'BNB'
    when os_tokens.project_name = 'BUSD' then 'BUSD'
    when os_tokens.project_name = 'ACRE' then 'ACRE'
    when os_tokens.project_name = 'arUSD'then 'ARUSD'
    when os_tokens.project_name = 'MARS' then 'MARS'
    when os_tokens.project_name = 'NGM' then 'NGM'
    END
    AS coin

    , CASE
    when coin = 'AVAX' then 'Bridge coin'
    when coin = 'BNB' then 'Bridge coin'
    when coin = 'BUSD' then 'Bridge coin'
    when coin = 'ACRE' then 'Native coin'
    Run a query to Download Data