-- 见 sqlite/000017 注释。hour = unix 纪元小时(UTC)。
CREATE TABLE usage_hourly (
  user_id      BIGINT UNSIGNED NOT NULL,
  hour         BIGINT NOT NULL,
  bytes_up     BIGINT UNSIGNED NOT NULL DEFAULT 0,
  bytes_down   BIGINT UNSIGNED NOT NULL DEFAULT 0,
  minutes_used INT NOT NULL DEFAULT 0,
  PRIMARY KEY (user_id, hour)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
