summaryrefslogtreecommitdiff
path: root/upgrading/3.2.0.txt
diff options
context:
space:
mode:
authorLukas Fleischer <archlinux@cryptocrack.de>2014-06-29 23:09:35 +0200
committerLukas Fleischer <archlinux@cryptocrack.de>2014-06-29 23:10:45 +0200
commit1fe14899aa808f50144162d6b14fc583873d08fc (patch)
tree9febba2c1876be4cd8f76c08e5a65b8697ddeee6 /upgrading/3.2.0.txt
parent5e49aca247a27dc0334e999dfb306e27ddbe99b9 (diff)
Split UPGRADING
Split the upgrade instructions into several files, one file per version in order to keep them small, readable and to avoid merge conflicts. Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Diffstat (limited to 'upgrading/3.2.0.txt')
-rw-r--r--upgrading/3.2.0.txt30
1 files changed, 30 insertions, 0 deletions
diff --git a/upgrading/3.2.0.txt b/upgrading/3.2.0.txt
new file mode 100644
index 0000000..cde9367
--- /dev/null
+++ b/upgrading/3.2.0.txt
@@ -0,0 +1,30 @@
+1. Add support for package requests to the database:
+
+----
+CREATE TABLE RequestTypes (
+ ID TINYINT UNSIGNED NOT NULL AUTO_INCREMENT,
+ Name VARCHAR(32) NOT NULL DEFAULT '',
+ PRIMARY KEY (ID)
+) ENGINE = InnoDB;
+INSERT INTO RequestTypes VALUES (1, 'deletion');
+INSERT INTO RequestTypes VALUES (2, 'orphan');
+INSERT INTO RequestTypes VALUES (3, 'merge');
+
+CREATE TABLE PackageRequests (
+ ID BIGINT UNSIGNED NOT NULL AUTO_INCREMENT,
+ ReqTypeID TINYINT UNSIGNED NOT NULL,
+ PackageBaseID INTEGER UNSIGNED NULL,
+ PackageBaseName VARCHAR(255) NOT NULL,
+ MergeBaseName VARCHAR(255) NULL,
+ UsersID INTEGER UNSIGNED NULL DEFAULT NULL,
+ Comments TEXT NOT NULL DEFAULT '',
+ RequestTS BIGINT UNSIGNED NOT NULL DEFAULT 0,
+ Status TINYINT UNSIGNED NOT NULL DEFAULT 0,
+ PRIMARY KEY (ID),
+ INDEX (UsersID),
+ INDEX (PackageBaseID),
+ FOREIGN KEY (ReqTypeID) REFERENCES RequestTypes(ID) ON DELETE NO ACTION,
+ FOREIGN KEY (UsersID) REFERENCES Users(ID) ON DELETE SET NULL,
+ FOREIGN KEY (PackageBaseID) REFERENCES PackageBases(ID) ON DELETE SET NULL
+) ENGINE = InnoDB;
+----