mo115bebop transaction type p
    Updated 2024-03-17
    with txs as (with t_in as (with txs_in as(
    SELECT
    'Polygon' as Network,TX_HASH,FROM_ADDRESS as wallet , SYMBOL,AMOUNT_USD
    from polygon.core.ez_token_transfers
    WHERE ( to_address = '0x0087bb802d9c0e343f00510000729031ce00bf27'or to_address ='0xaf0b0000f0210d0f421f0009c72406703b50506b'or to_address ='0x00000000ae347930bd1e7b0f35588b92280f9e75')
    and (ORIGIN_TO_ADDRESS = '0xbeb09beb09e95e6febf0d6eeb1d0d46d1013cc3c' or ORIGIN_TO_ADDRESS = '0x29fbd00940df70cfc5dad3f2370686991e2bbf5c' or ORIGIN_TO_ADDRESS = '0xaf0b0000f0210d0f421f0009c72406703b50506b'or ORIGIN_TO_ADDRESS = '0x00000000ae347930bd1e7b0f35588b92280f9e75')
    union
    SELECT
    'Arbitrum' as Network,TX_HASH,FROM_ADDRESS as wallet , SYMBOL,AMOUNT_USD
    from arbitrum.core.ez_token_transfers
    WHERE ( to_address = '0x0087bb802d9c0e343f00510000729031ce00bf27'or to_address ='0xaf0b0000f0210d0f421f0009c72406703b50506b'or to_address ='0x00000000ae347930bd1e7b0f35588b92280f9e75')
    and (ORIGIN_TO_ADDRESS = '0xbeb09beb09e95e6febf0d6eeb1d0d46d1013cc3c' or ORIGIN_TO_ADDRESS = '0x29fbd00940df70cfc5dad3f2370686991e2bbf5c' or ORIGIN_TO_ADDRESS = '0xaf0b0000f0210d0f421f0009c72406703b50506b'or ORIGIN_TO_ADDRESS = '0x00000000ae347930bd1e7b0f35588b92280f9e75')
    union
    SELECT
    'ethereum' as Network ,TX_HASH,FROM_ADDRESS as wallet , SYMBOL,AMOUNT_USD
    from ethereum.core.ez_token_transfers
    WHERE ( to_address = '0x0087bb802d9c0e343f00510000729031ce00bf27'or to_address ='0xaf0b0000f0210d0f421f0009c72406703b50506b'or to_address ='0x00000000ae347930bd1e7b0f35588b92280f9e75')
    and (ORIGIN_TO_ADDRESS = '0xbeb09beb09e95e6febf0d6eeb1d0d46d1013cc3c' or ORIGIN_TO_ADDRESS = '0x29fbd00940df70cfc5dad3f2370686991e2bbf5c' or ORIGIN_TO_ADDRESS = '0xaf0b0000f0210d0f421f0009c72406703b50506b'or ORIGIN_TO_ADDRESS = '0x00000000ae347930bd1e7b0f35588b92280f9e75')
    )
    select Network,TX_HASH, wallet , count(SYMBOL)as In_tokens,
    sum(AMOUNT_USD) as In_tokens_AMOUNT_USD
    from txs_in
    WHERE wallet = lower('{{Your_Wallet_Address}}')
    group by 1,2,3)

    ,
    t_out as ( with txs_out as(
    SELECT
    'Polygon' as Network,TX_HASH,to_address as wallet , SYMBOL as SYMBOLs,AMOUNT_USD
    from polygon.core.ez_token_transfers
    WHERE ( from_address = '0x0087bb802d9c0e343f00510000729031ce00bf27'or from_address ='0xaf0b0000f0210d0f421f0009c72406703b50506b'or from_address ='0x00000000ae347930bd1e7b0f35588b92280f9e75')
    and (ORIGIN_TO_ADDRESS = '0xbeb09beb09e95e6febf0d6eeb1d0d46d1013cc3c' or ORIGIN_TO_ADDRESS = '0x29fbd00940df70cfc5dad3f2370686991e2bbf5c' or ORIGIN_TO_ADDRESS = '0xaf0b0000f0210d0f421f0009c72406703b50506b'or ORIGIN_TO_ADDRESS = '0x00000000ae347930bd1e7b0f35588b92280f9e75')
    union
    SELECT
    'Arbitrum' as Network,TX_HASH,to_address as wallet , SYMBOL as SYMBOLs,AMOUNT_USD
    from arbitrum.core.ez_token_transfers
    QueryRunArchived: QueryRun has been archived