From 437de101ef48146628a76265c313ab30bd9c459f Mon Sep 17 00:00:00 2001 From: Son Do <34179343+Sunny77D@users.noreply.github.com> Date: Wed, 30 Oct 2024 10:54:58 -0400 Subject: [PATCH] Fixed Median Fees (#582) --- models/staging/scroll/fact_scroll_gas_gas_usd_revenue.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/models/staging/scroll/fact_scroll_gas_gas_usd_revenue.sql b/models/staging/scroll/fact_scroll_gas_gas_usd_revenue.sql index 591d5c23..0b4dcf00 100644 --- a/models/staging/scroll/fact_scroll_gas_gas_usd_revenue.sql +++ b/models/staging/scroll/fact_scroll_gas_gas_usd_revenue.sql @@ -4,7 +4,7 @@ with select to_timestamp(block_timestamp)::date as date, sum(gas_used * gas_price + l1_fee) / 1e18 as gas, - median(gas_used * gas_price + l1_fee) as median_gas, + median((gas_used * gas_price + l1_fee) / 1e18) as median_gas, 'scroll' as chain from {{ ref("fact_scroll_transactions") }} group by 1