mirror of
https://github.com/stonith404/pingvin-share.git
synced 2024-08-19 04:40:12 +02:00
18 lines
674 B
MySQL
18 lines
674 B
MySQL
|
-- RedefineTables
|
||
|
PRAGMA foreign_keys=OFF;
|
||
|
CREATE TABLE "new_Config" (
|
||
|
"updatedAt" DATETIME NOT NULL,
|
||
|
"key" TEXT NOT NULL PRIMARY KEY,
|
||
|
"type" TEXT NOT NULL,
|
||
|
"value" TEXT NOT NULL,
|
||
|
"description" TEXT NOT NULL,
|
||
|
"obscured" BOOLEAN NOT NULL DEFAULT false,
|
||
|
"secret" BOOLEAN NOT NULL DEFAULT true,
|
||
|
"locked" BOOLEAN NOT NULL DEFAULT false
|
||
|
);
|
||
|
INSERT INTO "new_Config" ("description", "key", "locked", "secret", "type", "updatedAt", "value") SELECT "description", "key", "locked", "secret", "type", "updatedAt", "value" FROM "Config";
|
||
|
DROP TABLE "Config";
|
||
|
ALTER TABLE "new_Config" RENAME TO "Config";
|
||
|
PRAGMA foreign_key_check;
|
||
|
PRAGMA foreign_keys=ON;
|