@@ -0,0 +1,4 @@
+-- This file should undo anything in `up.sql`
+DROP INDEX IF EXISTS word_statistics_bookid ;
+DROP INDEX IF EXISTS word_statistics_base ;
+DROP TABLE word_statistics ;
@@ -0,0 +1,19 @@
+-- word_statistics
+CREATE TABLE word_statistics
+(
+ id SERIAL PRIMARY KEY,
+ bookid INTEGER,
+ word TEXT,
+ count INTEGER,
+ base TEXT,
+ end1 TEXT,
+ end2 TEXT,
+ type INTEGER,
+ length INTEGER,
+ created_at TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP
+);
+
+-- 索引:pali
+CREATE INDEX word_statistics_bookid ON word_statistics (bookid);
+CREATE INDEX word_statistics_base ON word_statistics (base);