From: Nutomic Date: Wed, 7 Jun 2023 15:31:24 +0000 (+0200) Subject: Add db index for post.url column (#2929) X-Git-Url: http://these/git/sneer-club-logo.svg?a=commitdiff_plain;h=1c9f0c2bed51eb240d8514d28993c5516c019afc;p=lemmy.git Add db index for post.url column (#2929) * Add db index for post.url column As mentioned in https://github.com/LemmyNet/lemmy/issues/2877#issuecomment-1576439829 Not sure if its preferable to do this, or make a combined index which includes post.nsfw, post.removed, post.deleted * remove unique --- diff --git a/migrations/2023-06-06-104440_index_post_url/down.sql b/migrations/2023-06-06-104440_index_post_url/down.sql new file mode 100644 index 00000000..5a60b131 --- /dev/null +++ b/migrations/2023-06-06-104440_index_post_url/down.sql @@ -0,0 +1 @@ +drop index idx_post_url; diff --git a/migrations/2023-06-06-104440_index_post_url/up.sql b/migrations/2023-06-06-104440_index_post_url/up.sql new file mode 100644 index 00000000..4f8ea66f --- /dev/null +++ b/migrations/2023-06-06-104440_index_post_url/up.sql @@ -0,0 +1 @@ +create index idx_post_url on post(url);