CREATE TABLE last_smokes (
	nick CITEXT PRIMARY KEY,
	time TIMESTAMPTZ NOT NULL
);

INSERT INTO last_smokes (nick,time) (SELECT SUBSTR(id,6),value::timestamptz from misc WHERE id like 'SMOKE%');
