Query editor
with params as (select-- seconds since startTime (never below 0)greatest(date_diff('second', from_unixtime(1762553887), current_timestamp),0) as elapsed_seconds,30 * 86400 as halving_seconds -- 30 days)selectgreatest(((floor(elapsed_seconds / halving_seconds) + 1) * halving_seconds- elapsed_seconds) / 86400.0,0.0) as days_until_next_halvingfrom params;