CryptoGowdaNetflow in Wallet
    Updated 2023-02-15
    with
    erc20_transfers_outflow as (
    select
    date_trunc('hour', block_timestamp) as hour,
    to_address as address,
    tx_hash,
    amount,
    symbol
    from
    ethereum.core.ez_token_transfers
    where
    from_address = '0x4fafb87de15cff7448bd0658112f4e4b0d53332c'
    ),
    eth_transfers_outflow as (
    select
    date_trunc('hour', block_timestamp) as hour,
    ETH_TO_ADDRESS as address,
    tx_hash,
    amount,
    'WETH' AS symbol
    from
    ethereum.core.ez_eth_transfers
    where
    eth_from_address = '0x4fafb87de15cff7448bd0658112f4e4b0d53332c'
    ),
    combined_transfers_outflow as (
    select
    *
    from
    erc20_transfers_outflow
    UNION ALL
    select
    *
    from
    eth_transfers_outflow
    ),