SponsorBlockServer/databases/_upgrade_sponsorTimes_23.sql
2021-08-05 16:50:39 -04:00

12 lines
238 B
SQL

BEGIN TRANSACTION;
DELETE FROM "userNames" WHERE ctid NOT IN (
SELECT MIN(ctid) FROM "userNames"
GROUP BY "userID"
);
ALTER TABLE "userNames" ADD UNIQUE("userID");
UPDATE "config" SET value = 23 WHERE key = 'version';
COMMIT;