29.lua

main 14 lines · 427 bytes Raw
Alex Alex Commit Server upload 18/10/2026 23:38
1function onUpdateDatabase()
2 print("> Updating database to version 29 (account storages)")
3 db.query([[
4 CREATE TABLE IF NOT EXISTS `account_storage` (
5 `account_id` int NOT NULL,
6 `key` int unsigned NOT NULL,
7 `value` int NOT NULL,
8 PRIMARY KEY (`account_id`, `key`),
9 FOREIGN KEY (`account_id`) REFERENCES `accounts`(`id`) ON DELETE CASCADE
10 ) ENGINE=InnoDB DEFAULT CHARACTER SET=utf8;
11 ]])
12 return true
13end
14
Top