Add improved hashed ip index

This commit is contained in:
Ajay 2022-05-26 22:47:07 -04:00
parent 5e4773afdd
commit d273095525
2 changed files with 11 additions and 3 deletions

View file

@ -1,9 +1,8 @@
-- sponsorTimes -- sponsorTimes
CREATE INDEX IF NOT EXISTS "privateDB_sponsorTimes_v3" CREATE INDEX IF NOT EXISTS "privateDB_sponsorTimes_v4"
ON public."sponsorTimes" USING btree ON public."sponsorTimes" USING btree
("hashedIP" COLLATE pg_catalog."default" ASC NULLS LAST, "videoID" ASC NULLS LAST, service COLLATE pg_catalog."default" ASC NULLS LAST) ("videoID" ASC NULLS LAST, service COLLATE pg_catalog."default" ASC NULLS LAST, "timeSubmitted" ASC NULLS LAST);
;
-- votes -- votes

View file

@ -0,0 +1,9 @@
BEGIN TRANSACTION;
-- Add primary keys
DROP INDEX "privateDB_sponsorTimes_v3"; --!sqlite-ignore
UPDATE "config" SET value = 9 WHERE key = 'version';
COMMIT;