SyndicaArbitrum Activity Fees
    Updated 2024-12-03
    -- forked from Polygon Activity Fees @ https://flipsidecrypto.xyz/studio/queries/e7bfaaeb-0e8c-4505-be05-73b0941ddda9

    -- forked from Avalanche Activity Fees @ https://flipsidecrypto.xyz/studio/queries/3cb6d6ea-9f77-4dd6-b5a7-08025e436f2a

    -- forked from Avalanche Top Fees @ https://flipsidecrypto.xyz/studio/queries/ea39e418-c7d0-4d84-b76e-710eb61b7245

    -- forked from WillF-bduZ1b / SOL, MATIC, AVAX, BNB, ARB NFT Mints Gas Prices @ https://flipsidecrypto.xyz/WillF-bduZ1b/q/AcHTkiLNTSqg/sol-matic-avax-bnb-arb-nft-mints-gas-prices

    with

    contracts as (
    select
    b.address
    , c.label_type
    from arbitrum.core.dim_contracts b inner join arbitrum.core.dim_labels c
    on b.address = c.address
    where
    label_type in (
    'dapp'
    , 'games'
    , 'dex'
    , 'bridge'
    , 'defi'
    , 'nft'
    , 'token'
    )
    group by 1,2
    )

    select
    label_type
    , count(distinct tx.tx_hash) as transactions
    , avg(tx_fee * price / 100) as avg_gas_used_usd
    , median(tx_fee * price / 100) as median_gas_used_usd
    from arbitrum.core.fact_transactions tx inner join arbitrum.core.fact_traces a on tx.tx_hash = a.tx_hash
    inner join contracts b on a.to_address = b.address
    QueryRunArchived: QueryRun has been archived