0xaimanMost Popular Asset Bridged to Gnosis Chain
    Updated 2022-07-30
    with a as (select block_timestamp as t, tx_hash, event_inputs:recipient as user,
    event_inputs:token as token , event_inputs:value as value
    from gnosis.core.fact_event_logs
    where --tx_hash = '0xdb72a7c871d0098069ddad8bdc0534b5e52bf769fed2dce03476c3e0fd1eb779' and
    event_name = 'TokensBridged'),

    b as (
    select tx_hash
    from gnosis.core.fact_event_logs
    where event_name='Transfer' and event_inputs:from='0x0000000000000000000000000000000000000000'
    ),

    c as (
    SELECT t, user,a.tx_hash, token, value, address_name
    from a inner join b
    ON a.tx_hash=b.tx_hash
    left JOIN gnosis.core.dim_labels l ON l.address=a.token)

    SELECT token,CASE WHEN token='0x6a023ccd1ff6f2045c3309768ead9e68f978f6e1' then 'WETH'
    WHEN token='0x9c58bacc331c9aa871afd802db6379a98e80cedb' THEN 'GNO'
    WHEN token='0xddafbb505ad214d7b80b1f830fccc89b60fb7a83' THEN 'USDC'
    WHEN token='0xb7d311e2eb55f2f68a9440da38e7989210b9a05e' THEN 'STAKE'
    WHEN token='0x4ecaba5870353805a9f068101a40e0f32ed605c6' THEN 'USDT'
    WHEN token='0xca8d20f3e0144a72c6b5d576e9bd3fd8557e2b04' THEN 'wBNB'
    WHEN token='0x21a42669643f45bc0e086b8fc2ed70c23d67509d' THEN 'FOX'
    WHEN token='0x37b60f4e9a31a64ccc0024dce7d0fd07eaa0f7b3' THEN 'PNK'
    WHEN token='0x177127622c4a00f3d409b75571e12cb3c8973d3c' THEN 'COW'
    WHEN token='0x8e5bbbb09ed1ebde8674cda39a0c169401db4252' THEN 'wBTC'
    end as symbol
    , count(user) as n_user
    FROM c
    GROUP BY 1,2 order by 3 desc
    --where tx_hash = '0xc0fee9572f544e43d335b7062a8fb1c2bb18bd55a94aa2dc8cdd7e933b1341b0'
    limit 5 -- limit 100
    Run a query to Download Data