MahrooThe Total Contracts
    Updated 2022-08-03
    with deployer as ( select
    tx_hash ,
    block_timestamp::date as day ,
    tx_receiver
    from near.core.fact_transactions)
    ,
    contract as ( select
    tx_hash ,
    block_timestamp::date as day,
    action_name
    from near.core.fact_actions_events
    )
    ,
    final as ( select
    a.tx_hash ,
    a.day ,
    tx_receiver ,
    action_name
    from deployer a left outer join contract b on a.tx_hash = b.tx_hash and a.day = b.day
    )
    ,
    final1 as ( select
    min(day) as days ,
    tx_receiver
    from final
    where day >= '2022-01-01'
    and action_name = 'DeployContract'
    group by 2)
    ,
    first_tx as ( select
    days ,
    tx_receiver
    from final1
    where days >= CURRENT_DATE - 100)
    ,
    top_5 as ( select
    Run a query to Download Data