Holonymwallet age- zkpass
    Updated 2025-02-03
    with zkPass as ( select
    d.value:"USER" as address
    from (
    select livequery.live.udf_api(
    'https://flipsidecrypto.xyz/api/v1/queries/95dc91ce-8ff4-49be-b520-d722e29143dc/data/latest'
    ):"data" as data
    ) responses join lateral flatten (input => responses.data) d
    ),


    total as (

    select * from zkPass
    ),

    t2 as(
    select
    from_address as users,
    -- Count(distinct tx_hash) as no_txn,
    -- count (Distinct block_timestamp::Date) as active_days,
    min (block_timestamp) as first_transaction,
    datediff(day,first_transaction,CURRENT_DATE) as wallet_age
    from ethereum.core.fact_transactions
    where from_address in (select address from total)
    group by 1

    union all

    select
    from_address as users,
    -- Count(distinct tx_hash) as no_txn,
    -- count (Distinct block_timestamp::Date) as active_days,
    min (block_timestamp) as first_transaction,
    datediff(day,first_transaction,CURRENT_DATE) as wallet_age
    from avalanche.core.fact_transactions
    where from_address in (select address from total)
    QueryRunArchived: QueryRun has been archived