therealestbera3. failure/success line chart
    Updated 2024-08-25
    -- forked from 2. failure/success history graphs @ https://flipsidecrypto.xyz/studio/queries/99905933-2553-4e29-bf29-c0932923536b

    -- forked from 1. TX history with details latest @ https://flipsidecrypto.xyz/studio/queries/98ff20de-90a8-46cb-b6f9-dd8fbdce62ea

    -- forked from 1. TX history with details @ https://flipsidecrypto.xyz/studio/queries/5707f729-c0cc-4b22-aebd-5558a7f85288





    WITH tx_data AS (
    SELECT
    BLOCK_NUMBER,
    BLOCK_TIMESTAMP,
    TX_HASH,
    FROM_ADDRESS,
    VALUE,
    TX_SUCCEEDED
    FROM berachain.testnet.fact_transactions
    WHERE TO_ADDRESS = LOWER('0x14D65204c710997F595F4663f0451b66d3532f53')
    AND ORIGIN_FUNCTION_SIGNATURE = '0x8bbefe4b'
    ORDER BY BLOCK_NUMBER ASC
    ),
    rounds AS (
    SELECT
    BLOCK_NUMBER,
    BLOCK_TIMESTAMP,
    TX_HASH,
    CONCAT('0x', SUBSTR(TOPICS[1], 27, 64)) AS FROM_ADDRESS,
    (utils.udf_hex_to_int(SUBSTR(data, 67, 64))::int) / 1e18 AS pot_before,
    (utils.udf_hex_to_int(SUBSTR(data, 131, 64))::int) / 1e18 AS pot_after,
    utils.udf_hex_to_int(SUBSTR(data, 323, 64))::int AS yeet_count,
    utils.udf_hex_to_int(SUBSTR(data, 387, 64))::int AS yeet_round
    FROM berachain.testnet.fact_event_logs
    WHERE ORIGIN_TO_ADDRESS = LOWER('0x14D65204c710997F595F4663f0451b66d3532f53')
    AND ORIGIN_FUNCTION_SIGNATURE = '0x8bbefe4b'
    QueryRunArchived: QueryRun has been archived