aboutsummaryrefslogtreecommitdiff
path: root/sql
diff options
context:
space:
mode:
authorHolger Weiss <holger@zedat.fu-berlin.de>2019-02-26 13:13:04 +0100
committerHolger Weiss <holger@zedat.fu-berlin.de>2019-02-26 13:13:04 +0100
commit90dc8ea1e5566d430c8a871e076b11e37e1a1090 (patch)
tree7a24730c32e0daed966bb7ba70d6ca08b81760fa /sql
parentUpdate mqtree (diff)
MySQL: Increase index prefix length for PEP nodes
For PEP nodes, the "host" column holds the user JID, where the first 20 characters may well not be unique.
Diffstat (limited to 'sql')
-rw-r--r--sql/mysql.new.sql2
-rw-r--r--sql/mysql.sql2
2 files changed, 2 insertions, 2 deletions
diff --git a/sql/mysql.new.sql b/sql/mysql.new.sql
index 65b6d1b78..39df58c55 100644
--- a/sql/mysql.new.sql
+++ b/sql/mysql.new.sql
@@ -242,7 +242,7 @@ CREATE TABLE pubsub_node (
nodeid bigint auto_increment primary key
) ENGINE=InnoDB CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
CREATE INDEX i_pubsub_node_parent ON pubsub_node(parent(120));
-CREATE UNIQUE INDEX i_pubsub_node_tuple ON pubsub_node(host(20), node(120));
+CREATE UNIQUE INDEX i_pubsub_node_tuple ON pubsub_node(host(71), node(120));
CREATE TABLE pubsub_node_option (
nodeid bigint,
diff --git a/sql/mysql.sql b/sql/mysql.sql
index 2dc02bf69..0e3c826ef 100644
--- a/sql/mysql.sql
+++ b/sql/mysql.sql
@@ -219,7 +219,7 @@ CREATE TABLE pubsub_node (
nodeid bigint auto_increment primary key
) ENGINE=InnoDB CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
CREATE INDEX i_pubsub_node_parent ON pubsub_node(parent(120));
-CREATE UNIQUE INDEX i_pubsub_node_tuple ON pubsub_node(host(20), node(120));
+CREATE UNIQUE INDEX i_pubsub_node_tuple ON pubsub_node(host(71), node(120));
CREATE TABLE pubsub_node_option (
nodeid bigint,