chispasYOYOO helius json parse
    WITH Sol_Price as (
    select
    date_trunc(day, RECORDED_HOUR) as date,
    avg(CLOSE) as price
    from solana.core.fact_token_prices_hourly
    where
    RECORDED_HOUR::date >= current_date - 30
    and SYMBOL ilike 'sol'
    group by 1
    ),
    buy as (
    select
    BLOCK_TIMESTAMP,
    PURCHASER,
    MINT as NFT_ADDRESS,
    SALES_AMOUNT * price as Buy_Price
    from solana.core.fact_nft_sales join Sol_Price on BLOCK_TIMESTAMP::date = date
    where BLOCK_TIMESTAMP::date >= current_date - 30
    and SALES_AMOUNT is not null
    and SUCCEEDED
    ),
    sell as (
    select
    BLOCK_TIMESTAMP,
    SELLER,
    MINT as NFT_ADDRESS,
    SALES_AMOUNT * price as Sell_Price
    from solana.core.fact_nft_sales join Sol_Price on BLOCK_TIMESTAMP::date = date
    where BLOCK_TIMESTAMP::date >= current_date - 30
    and SALES_AMOUNT is not null
    and SUCCEEDED
    )
    ,
    Net as (
    select
    seller as Trader,
    Run a query to Download Data