LittlerDatapolymarket example mergeposition per questionId
    Updated 2024-01-09
    -- forked from polymarket example mergeposition @ https://flipsidecrypto.xyz/edit/queries/221fd757-bb00-4100-b0ec-07e54d445f9a

    with mergePosition as (
    select
    *
    from polygon.core.ez_decoded_event_logs
    where 1=1
    --and tx_hash = '0xf2c15787f6c56a80c4b16bd34ec277e4aa316c42cf6544ef434e010cfc903f4b'
    and block_timestamp > '2023-09-29'
    --and event_name = 'PositionSplit'
    and contract_address = '0x4d97dcd97ec945f40cf65f87097ace5ea0476045'
    and decoded_log:questionId = '0xf0cbd0335d07a250870dab62a91480572c3b2a40fe3c8504d31160012a1bfe39'
    )

    select
    *
    from polygon.core.ez_decoded_event_logs
    where tx_hash in (select tx_hash from mergePosition)


    QueryRunArchived: QueryRun has been archived