|
|
@ -1,16 +1,16 @@ |
|
|
|
CREATE TABLE IF NOT EXISTS registration_codes ( |
|
|
|
code VARCHAR(60) NOT NULL UNIQUE, |
|
|
|
creationTime TIMESTAMP NOT NULL, |
|
|
|
CREATE TABLE IF NOT EXISTS registration_codes |
|
|
|
( |
|
|
|
code VARCHAR(60) NOT NULL UNIQUE, |
|
|
|
creationTime TIMESTAMP NOT NULL, |
|
|
|
expirationTime TIMESTAMP, |
|
|
|
usages INTEGER NOT NULL DEFAULT 0, |
|
|
|
maxUsages Integer NOT NULL DEFAULT 1 |
|
|
|
usages INTEGER NOT NULL DEFAULT 0, |
|
|
|
maxUsages Integer NOT NULL DEFAULT 1 |
|
|
|
); |
|
|
|
|
|
|
|
CREATE TABLE IF NOT EXISTS registered_users ( |
|
|
|
registrationCode VARCHAR(60) NOT NULL UNIQUE, |
|
|
|
username VARCHAR(30) NOT NULL UNIQUE, |
|
|
|
registeredTime TIMESTAMP NOT NULL |
|
|
|
); |
|
|
|
|
|
|
|
ALTER TABLE registered_users |
|
|
|
ADD COLUMN registeredUserId VARCHAR(60); |
|
|
|
CREATE TABLE IF NOT EXISTS registered_users |
|
|
|
( |
|
|
|
registrationCode VARCHAR(60) NOT NULL UNIQUE, |
|
|
|
username VARCHAR(30) NOT NULL UNIQUE, |
|
|
|
registeredUserId VARCHAR(60) NOT NULL UNIQUE, |
|
|
|
registeredTime TIMESTAMP NOT NULL |
|
|
|
); |