This commit is contained in:
shoopea 2019-05-14 10:39:37 +08:00
parent 16370db3aa
commit 0b14e0d5ce

6
sql.go
View File

@ -192,9 +192,9 @@ func initDB() {
,castle_id SMALLINT UNSIGNED NOT NULL
,gardian TINYINT NOT NULL
,result VARCHAR(8)
,gold SMALLINT NOT NULL
,stock SMALLINT NOT NULL
,points SMALLINT NOT NULL
,gold INT NOT NULL
,stock INT NOT NULL
,points INT NOT NULL
,FOREIGN KEY (obj_id) REFERENCES obj(id) ON DELETE CASCADE
,FOREIGN KEY (castle_id) REFERENCES code_obj_castle(id) ON DELETE CASCADE
,UNIQUE KEY (obj_id, castle_id)