aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2020-12-05 17:07:09 -0300
committerSilvio Rhatto <rhatto@riseup.net>2020-12-05 17:07:09 -0300
commit56c2cc72b9e4f65d94edab5f4c58633322dc43f8 (patch)
tree1602e83b41b95e2cd0ba026fdf26ffa0f3cd8471
parentf9b94e3ba677fd19c311fdde7cd9da8709953000 (diff)
downloadsemanticscuttle-56c2cc72b9e4f65d94edab5f4c58633322dc43f8.tar.gz
semanticscuttle-56c2cc72b9e4f65d94edab5f4c58633322dc43f8.tar.bz2
Fix: create an index at sc_bookmarks2tags table
This index increases the performance of queries that selects tags from a given bookmark.
-rw-r--r--data/schema/7.sql1
-rw-r--r--data/tables.sql2
2 files changed, 3 insertions, 0 deletions
diff --git a/data/schema/7.sql b/data/schema/7.sql
new file mode 100644
index 0000000..28694fa
--- /dev/null
+++ b/data/schema/7.sql
@@ -0,0 +1 @@
+CREATE INDEX sc_bookmarks2tags_index ON sc_bookmarks2tags(tag);
diff --git a/data/tables.sql b/data/tables.sql
index de1bb8d..86779c2 100644
--- a/data/tables.sql
+++ b/data/tables.sql
@@ -59,6 +59,8 @@ CREATE TABLE `sc_bookmarks2tags` (
KEY `sc_bookmarks2tags_bId` (`bId`)
) CHARACTER SET utf8 COLLATE utf8_general_ci ;
+CREATE INDEX sc_bookmarks2tags_index ON sc_bookmarks2tags(tag);
+
-- --------------------------------------------------------
--