Afonso_DiazTop symbols
    Updated 2025-01-03
    with

    main as (
    select
    tx_hash,
    block_timestamp,
    origin_from_address as swapper,
    platform,
    symbol_in,
    symbol_out,
    nvl(amount_in_usd,amount_out_usd) as amount_usd
    from
    base.defi.ez_dex_swaps
    where
    amount_usd between 0 and 1e7
    and block_timestamp between '{{ start_date }}' and '{{ end_date }}'
    ),

    final as (
    select
    symbol_in as symbol,
    tx_hash,
    amount_usd,
    swapper
    from main

    union all

    select
    symbol_out as symbol,
    tx_hash,
    amount_usd,
    swapper
    from main
    )

    QueryRunArchived: QueryRun has been archived