datavortexattractive-salmon
    Updated 2025-02-18
    SELECT
    COUNT(DISTINCT CASE
    WHEN action_type IN ('deposit') THEN provider_address
    END) AS total_stakers,
    COUNT(DISTINCT CASE
    WHEN action_type IN ('claim') THEN provider_address
    END) AS total_unstakers,
    COUNT(DISTINCT CASE
    WHEN action_type IN ('deposit') THEN tx_id
    END) AS total_stake_tx_ids,
    COUNT(DISTINCT CASE
    WHEN action_type IN ('claim') THEN tx_id
    END) AS total_unstake_tx_ids,
    SUM(CASE
    WHEN action_type IN ('deposit') THEN deposit_amount
    ELSE 0
    END) AS total_stake_usd,
    SUM(CASE
    WHEN action_type IN ('claim') THEN claim_amount
    ELSE 0
    END) AS total_unstake_usd
    FROM
    solana.marinade.ez_liquid_staking_actions
    WHERE
    action_type IN ('deposit', 'claim');

    QueryRunArchived: QueryRun has been archived