MultipartiteEVM cancel transactions
    Updated 2024-04-29
    WITH
    evm_asgards AS (
    SELECT DISTINCT from_address
    FROM thorchain.defi.fact_outbound_events
    WHERE block_timestamp > '2023-12-31'
    AND blockchain IN ('ETH', 'AVAX', 'BSC')
    ),

    eth AS (
    SELECT block_timestamp,
    'ETH' as chain,
    --SUM(tx_fee) OVER(ORDER BY block_number ASC) AS chain_cumulative_tx_fee,
    tx_fee, from_address, block_number, tx_hash
    FROM ethereum.core.fact_transactions
    WHERE block_timestamp > '2023-12-31'
    AND value = 0
    AND origin_function_signature = '0x'
    AND from_address IN (SELECT from_address FROM evm_asgards)
    ),

    avax AS (
    SELECT block_timestamp,
    'AVAX' as chain,
    --SUM(tx_fee) OVER(ORDER BY block_number ASC) AS chain_cumulative_tx_fee,
    tx_fee, from_address, block_number, tx_hash
    FROM avalanche.core.fact_transactions
    WHERE block_timestamp > '2023-12-31'
    AND value = 0
    AND origin_function_signature = '0x'
    AND from_address IN (SELECT from_address FROM evm_asgards)
    ),

    bsc AS (
    SELECT block_timestamp,
    'BSC' as chain,
    --SUM(tx_fee) OVER(ORDER BY block_number ASC) AS chain_cumulative_tx_fee,
    QueryRunArchived: QueryRun has been archived