rezarwz# of tardes and volume
    Updated 2024-07-05
    with all_pac_bot as (
    SELECT
    BLOCK_TIMESTAMP,
    TX_HASH,
    EVENT_NAME,
    DECODED_LOG:token as token_Address,
    ORIGIN_FROM_ADDRESS as ua
    FROM
    blast.core.ez_decoded_event_logs
    where
    contract_Address = '0xd2261bd8b30a305526826e4b0cee8580df5b33ee'
    ),
    all_trades as (
    SELECT
    tx.*,
    tr_Sell.symbol,
    et_sell.amount,
    et_sell.amount_usd as usd_amount
    FROM
    all_pac_bot tx
    inner join blast.core.ez_token_transfers tr_Sell on tx.tx_hash = tr_Sell.tx_hash
    and tx.EVENT_NAME = 'Sell'
    and tr_sell.from_Address = tx.ua
    inner join blast.core.ez_native_transfers et_sell on tx.tx_hash = et_Sell.tx_hash
    and tx.EVENT_NAME = 'Sell'
    and et_sell.to_Address = tx.ua
    UNION
    all
    SELECT
    tx.*,
    tr_buy.symbol,
    et_buy.amount,
    et_buy.amount_usd as usd_amount
    FROM
    all_pac_bot tx
    inner join blast.core.ez_token_transfers tr_buy on tx.tx_hash = tr_buy.tx_hash
    QueryRunArchived: QueryRun has been archived