CryptoIcicleEthereum -> NEAR Bridge Txns - NFT Buyers
    Updated 2022-08-29
    -- NEAR Tournament Round IV: The Journeymen
    -- The foundations of a great city are built by its citizens; where they’ve been, where they’ll go, what they do along the way.

    -- Payout 42 NEAR
    -- Grand Prize 126 NEAR
    -- Payout Network Near
    -- Level Intermediate
    -- Difficulty Hard

    -- Analyze the journey of active NEAR users.
    -- After bridging to NEAR, where do they head first?
    -- How many users are day trading in the financial district,
    -- and how many are buyers and sellers on the NFT marketplaces of the Arts district?
    -- Who are the whales, and is their activity any different from that of smaller fish?
    -- Top submissions should provide an in-depth analysis of the typical NEAR user journey, from small fish to the biggest whales.

    -- SQL Credit https://app.flipsidecrypto.com/velocity/queries/58ada2c8-1d80-4d5f-817e-a83a810a56fd
    -- Dashboard: https://app.flipsidecrypto.com/dashboard/near-citizens-fQRyBU
    -- SQL Credit https://app.flipsidecrypto.com/velocity/queries/9af989e2-9cfc-4a62-8499-1767a8c43189
    -- Dashboard: https://app.flipsidecrypto.com/dashboard/near-arts-district-m8p1bd

    with bridge_erc20_to_near as (
    select el.block_timestamp::date as date,
    tx_hash,
    event_inputs:accountId as receiver,
    event_inputs:sender as sender,
    event_inputs:token as token_address,
    symbol,
    (event_inputs:amount)/pow(10, decimals) as amount
    from ethereum.core.fact_event_logs el
    left join ethereum.core.dim_contracts_extended ec on el.event_inputs:token=ec.contract_address
    where ORIGIN_TO_ADDRESS = '0x23ddd3e3692d1861ed57ede224608875809e127f' -- Near: Rainbow bridge
    and CONTRACT_NAME = 'ERC20Locker'
    and EVENT_NAME = 'Locked'
    and ORIGIN_FUNCTION_SIGNATURE = '0x0889bfe7'
    and symbol is not null
    Run a query to Download Data