messariCandyV3 initialize collections
    Updated 2023-01-14
    with
    base as (
    select
    t.block_timestamp,
    t.tx_id,
    t.signers[0] as wallet,
    --t.instructions,
    t.instructions[0]:parsed:info:owner as owner,
    t.log_messages
    from
    solana.core.fact_events e
    inner join solana.core.fact_transactions t on e.tx_id = t.tx_id
    where
    date(t.block_timestamp) >= current_date() - 3
    and e.program_id = 'CndyV3LdqHUfDLmE5naZjVN8rBZz4tqhdefbAnjHG3JR'
    and t.succeeded = 'TRUE'
    -- Need to make this generic
    --and 'Program log: Instruction: Initialize' = t.log_messages[1]
    -- The problem with this is it catches 'Program log: Instruction: InitializeMint'
    --and log_messages::string like '%Program log: Instruction: Initialize%'
    --Program log: Instruction: Mint
    )
    select
    *
    from
    base
    order by
    block_timestamp desc
    limit
    1000;
    Run a query to Download Data