Flipside Data ScienceFlipside Ethereum Tables Last Entry
    Updated 2024-01-12
    with cte as (
    select 1 as index, 'ethereum.core.fact_transactions' as flipside_table, max(block_timestamp) as last_entry
    from ethereum.core.fact_transactions where block_timestamp > current_date
    union
    select 2, 'ethereum.core.fact_event_logs', max(block_timestamp)
    from ethereum.core.fact_event_logs where block_timestamp > current_date
    union
    select 3, 'ethereum.nft.ez_nft_sales', max(block_timestamp)
    from ethereum.nft.ez_nft_sales where block_timestamp > current_date
    union
    select 4, 'ethereum.defi.ez_dex_swaps', max(block_timestamp)
    from ethereum.defi.ez_dex_swaps where block_timestamp > current_date
    union
    select 5, 'ethereum.nft.ez_nft_mints', max(block_timestamp)
    from ethereum.nft.ez_nft_mints where block_timestamp > current_date
    ORDER by 1
    )
    SELECT *,
    TO_TIMESTAMP_NTZ(current_timestamp) as last_query_run,
    datediff('minute', TO_TIMESTAMP_NTZ(current_timestamp), last_entry) as lag_in_minutes
    from cte




    QueryRunArchived: QueryRun has been archived