Update of /cvsroot/php-blog/serendipity/sql
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv25401/sql
Modified Files:
db.sql
Added Files:
db_update_0.6.5_0.6.6_mysql.sql
db_update_0.6.5_0.6.6_postgres.sql
Log Message:
The entrycat table needs a key, or else the fetchEntries() function will
perform extremely slowly. On my blog with 390 entries the query was taking
12 seconds, which is now reduced to about 0.8 seconds...
--- NEW FILE: db_update_0.6.5_0.6.6_mysql.sql ---
CREATE UNIQUE INDEX entryid ON {PREFIX}entrycat (entryid, categoryid);
--- NEW FILE: db_update_0.6.5_0.6.6_postgres.sql ---
CREATE UNIQUE INDEX entryid ON {PREFIX}entrycat (entryid, categoryid);
Index: db.sql
===================================================================
RCS file: /cvsroot/php-blog/serendipity/sql/db.sql,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -d -r1.13 -r1.14
--- db.sql 17 Jun 2004 20:13:49 -0000 1.13
+++ db.sql 18 Jun 2004 09:04:39 -0000 1.14
@@ -170,9 +170,11 @@
path text
);
+CREATE {FULLTEXT} INDEX pathkey on {PREFIX}images (path);
+
CREATE TABLE {PREFIX}entrycat (
entryid int(11) not null,
categoryid int(11) not null
);
-CREATE {FULLTEXT} INDEX pathkey on {PREFIX}images (path);
+CREATE UNIQUE INDEX entryid ON {PREFIX}entrycat (entryid, categoryid);
|