davidwallUntitled Query
    Updated 2023-01-14
    --credit : https://app.flipsidecrypto.com/velocity/queries/e2693594-3881-44be-b912-063d944a76d0
    with cextable as (
    select distinct address from crosschain.core.address_labels
    where label_type = 'cex' and blockchain in ('ethereum','avalanche','arbitrum','binance smart chain','bsc','optimism','polygon')

    union ALL

    select distinct address from ethereum.core.dim_labels
    where label_type = 'cex'

    union all

    select distinct address from arbitrum.core.dim_labels
    where label_type = 'cex'

    union ALL

    select distinct address from avalanche.core.dim_labels
    where label_type = 'cex'
    union ALL
    select distinct address from bsc.core.dim_labels
    where label_type = 'cex'
    union ALL
    select distinct address from optimism.core.dim_labels
    where label_type = 'cex'

    union ALL
    select distinct address from polygon.core.dim_labels
    where label_type = 'cex')

    select 'Ethereum' as chain,
    Run a query to Download Data