Skip to content
Snippets Groups Projects
Commit f4309f44 authored by Bartek Wrona's avatar Bartek Wrona Committed by Dan Notestein
Browse files

Upgrade code supplemented by changes incorporated by this MR

parent d29a80d1
No related branches found
No related tags found
2 merge requests!827Merge develop changes to master,!686One of hive_follows indexes extended by `id` column to eliminate HEAP sort...
...@@ -38,6 +38,33 @@ END ...@@ -38,6 +38,33 @@ END
$$ $$
; ;
--- https://gitlab.syncad.com/hive/hivemind/-/merge_requests/686/
CREATE INDEX IF NOT EXISTS hive_follows_follower_where_blacklisted_idx
ON hivemind_app.hive_follows USING btree
(follower ASC NULLS LAST)
TABLESPACE haf_tablespace
WHERE blacklisted;
CREATE INDEX IF NOT EXISTS hive_follows_follower_where_follow_blacklists_idx
ON hivemind_app.hive_follows USING btree
(follower ASC NULLS LAST)
TABLESPACE haf_tablespace
WHERE follow_blacklists;
CREATE INDEX IF NOT EXISTS hive_follows_follower_where_follow_muted_idx
ON hivemind_app.hive_follows USING btree
(follower ASC NULLS LAST)
TABLESPACE haf_tablespace
WHERE follow_muted;
CREATE INDEX IF NOT EXISTS hive_follows_following_state_id_idx
ON hivemind_app.hive_follows USING btree
(following ASC NULLS LAST, state ASC NULLS LAST, id ASC NULLS LAST)
TABLESPACE haf_tablespace;
DROP INDEX IF EXISTS hivemind_app.hive_follows_following_state_idx;
--- Must be at the end --- Must be at the end
TRUNCATE TABLE hivemind_app.hive_db_data_migration; TRUNCATE TABLE hivemind_app.hive_db_data_migration;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment