MLDZMNENI13
    Updated 2023-01-04
    with owner as (
    select * from (
    SELECT
    block_timestamp,
    tx_hash,
    PROJECT_NAME,
    TOKENID as mint,
    BUYER_ADDRESS as purchaser,
    Price as amount,
    row_number() over(PARTITION BY TOKENID ORDER BY block_timestamp desc) rn
    from ethereum.core.ez_nft_sales
    where BLOCK_TIMESTAMP between '2022-01-01' and '2023-01-01'
    and Price>0
    ) where rn = 1 order by block_timestamp desc
    )
    select
    PROJECT_NAME,
    count(mint) as bear_owned
    from owner
    group by PROJECT_NAME having PROJECT_NAME is not null
    order by bear_owned desc limit 10
    Run a query to Download Data