mirror of
https://github.com/ajayyy/SponsorBlockServer.git
synced 2026-03-18 03:45:37 +03:00
Add segment locking
This commit is contained in:
27
databases/_upgrade_sponsorTimes_6.sql
Normal file
27
databases/_upgrade_sponsorTimes_6.sql
Normal file
@@ -0,0 +1,27 @@
|
||||
BEGIN TRANSACTION;
|
||||
|
||||
/* Add new voting field */
|
||||
CREATE TABLE "sqlb_temp_table_6" (
|
||||
"videoID" TEXT NOT NULL,
|
||||
"startTime" REAL NOT NULL,
|
||||
"endTime" REAL NOT NULL,
|
||||
"votes" INTEGER NOT NULL,
|
||||
"locked" INTEGER NOT NULL default '0',
|
||||
"incorrectVotes" INTEGER NOT NULL default '1',
|
||||
"UUID" TEXT NOT NULL UNIQUE,
|
||||
"userID" TEXT NOT NULL,
|
||||
"timeSubmitted" INTEGER NOT NULL,
|
||||
"views" INTEGER NOT NULL,
|
||||
"category" TEXT NOT NULL DEFAULT "sponsor",
|
||||
"shadowHidden" INTEGER NOT NULL,
|
||||
"hashedVideoID" TEXT NOT NULL default ""
|
||||
);
|
||||
|
||||
INSERT INTO sqlb_temp_table_6 SELECT videoID,startTime,endTime,votes,"0",incorrectVotes,UUID,userID,timeSubmitted,views,category,shadowHidden,hashedVideoID FROM sponsorTimes;
|
||||
|
||||
DROP TABLE sponsorTimes;
|
||||
ALTER TABLE sqlb_temp_table_6 RENAME TO "sponsorTimes";
|
||||
|
||||
UPDATE config SET value = 6 WHERE key = "version";
|
||||
|
||||
COMMIT;
|
||||
Reference in New Issue
Block a user