From 5022cfb9ee309475c2110994dfff86a7f32d614e Mon Sep 17 00:00:00 2001 From: "C. McEnroe" Date: Wed, 25 Dec 2019 18:08:54 -0500 Subject: Treat topics like motds It's more like a cache of existing topics. events is still meant to record actual topic events. --- database.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'database.h') diff --git a/database.h b/database.h index fa0dc10..810ce94 100644 --- a/database.h +++ b/database.h @@ -226,9 +226,10 @@ static const char *InitSQL = SQL( ); CREATE TABLE topics ( - context INTEGER NOT NULL REFERENCES contexts, time DATETIME NOT NULL, - topic TEXT + context INTEGER NOT NULL REFERENCES contexts, + topic TEXT NOT NULL, + UNIQUE (context, topic) ); CREATE TABLE names ( -- cgit 1.4.1