Select
Date_trunc('hour', block_timestamp) as date,
Count(distinct tx_id) as total_transactions,
Count(
case
when succeeded = 'false' then 1
end
) as transection_failed,
(transection_failed * 100) / total_transactions as failed_Ratio
From
solana.Core.Fact_transactions
Where
block_timestamp >= CURRENT_DATE - 7
Group by
1