· 8 years ago · Dec 17, 2017, 02:06 PM
1/*
2Navicat MySQL Data Transfer
3
4Source Database : gta5_gamemode_essential
5
6*/
7
8SET FOREIGN_KEY_CHECKS=0;
9
10-- ----------------------------
11-- Table structure for `items`
12-- ----------------------------
13DROP TABLE IF EXISTS `items`;
14CREATE TABLE `items` (
15 `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
16 `libelle` varchar(255) DEFAULT NULL,
17 `value` int(11) NOT NULL DEFAULT '0',
18 `type` int(11) NOT NULL DEFAULT '0',
19 PRIMARY KEY (`id`)
20) ENGINE=InnoDB AUTO_INCREMENT=25 DEFAULT CHARSET=utf8;
21
22-- ----------------------------
23-- Records of items
24-- ----------------------------
25INSERT INTO `items` VALUES ('1', 'Bouteille d\'eau', '20', '1');
26INSERT INTO `items` VALUES ('2', 'Sandwich', '20', '2');
27INSERT INTO `items` VALUES ('3', 'Drugs', '0', '0');
28
29SET FOREIGN_KEY_CHECKS=0;
30
31-- ----------------------------
32-- Table structure for `user_inventory`
33-- ----------------------------
34DROP TABLE IF EXISTS `user_inventory`;
35CREATE TABLE `user_inventory` (
36 `user_id` varchar(255) CHARACTER SET utf8mb4 NOT NULL DEFAULT '',
37 `item_id` int(11) unsigned NOT NULL,
38 `quantity` int(11) DEFAULT NULL,
39 PRIMARY KEY (`user_id`,`item_id`),
40 KEY `item_id` (`item_id`),
41 CONSTRAINT `user_inventory_ibfk_2` FOREIGN KEY (`item_id`) REFERENCES `items` (`id`)
42) ENGINE=InnoDB DEFAULT CHARSET=utf8;