summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoralecpl <alec@alec.pl>2009-09-13 08:12:58 +0000
committeralecpl <alec@alec.pl>2009-09-13 08:12:58 +0000
commit7fec6b2de7d827fd34785000c9cef7f5defa86f1 (patch)
tree0fad74a779566d7a1ca7de83807f3a65d5293626
parent9ab7bc6b169619ac82c8e93f111d8d8fa905a2b8 (diff)
- "TRUNCATE messages" is required to remove buggy cache entries
-rw-r--r--SQL/mysql.update.sql2
-rw-r--r--SQL/postgres.update.sql1
-rw-r--r--SQL/sqlite.update.sql1
3 files changed, 4 insertions, 0 deletions
diff --git a/SQL/mysql.update.sql b/SQL/mysql.update.sql
index f0cac2449..7091f30a0 100644
--- a/SQL/mysql.update.sql
+++ b/SQL/mysql.update.sql
@@ -49,3 +49,5 @@ ALTER TABLE `users`
ALTER TABLE `messages`
ADD INDEX `index_index` (`user_id`, `cache_key`, `idx`);
+
+TRUNCATE `messages`;
diff --git a/SQL/postgres.update.sql b/SQL/postgres.update.sql
index 6aba9b6a1..fe88a6dcc 100644
--- a/SQL/postgres.update.sql
+++ b/SQL/postgres.update.sql
@@ -40,3 +40,4 @@ ALTER TABLE messages ALTER del TYPE smallint;
-- Updates from version 0.3-stable
CREATE INDEX messages_index_idx ON messages (user_id, cache_key, idx);
+TRUNCATE messages;
diff --git a/SQL/sqlite.update.sql b/SQL/sqlite.update.sql
index 5c68cbb36..4b1b10b7f 100644
--- a/SQL/sqlite.update.sql
+++ b/SQL/sqlite.update.sql
@@ -40,3 +40,4 @@ CREATE INDEX ix_cache_created ON cache (created);
DROP INDEX ix_messages_user_cache_uid;
CREATE UNIQUE INDEX ix_messages_user_cache_uid ON messages (user_id,cache_key,uid);
CREATE INDEX ix_messages_index ON messages (user_id,cache_key,idx);
+TRUNCATE messages;