aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Data/MySQL
diff options
context:
space:
mode:
authorSean Dague2008-06-12 14:44:52 +0000
committerSean Dague2008-06-12 14:44:52 +0000
commit4387744a78ec9ce098a818dbf9b04cc3704a13f6 (patch)
tree85e44a986de66a316f1d75e5066b726418840b4e /OpenSim/Data/MySQL
parent* Insulate maptile volume draw routine against TextureEntry oddities. (diff)
downloadopensim-SC-4387744a78ec9ce098a818dbf9b04cc3704a13f6.zip
opensim-SC-4387744a78ec9ce098a818dbf9b04cc3704a13f6.tar.gz
opensim-SC-4387744a78ec9ce098a818dbf9b04cc3704a13f6.tar.bz2
opensim-SC-4387744a78ec9ce098a818dbf9b04cc3704a13f6.tar.xz
check in migration files for mysql
Diffstat (limited to '')
-rw-r--r--OpenSim/Data/MySQL/Resources/001_AssetStore.sql11
-rw-r--r--OpenSim/Data/MySQL/Resources/001_InventoryStore.sql35
-rw-r--r--OpenSim/Data/MySQL/Resources/001_UserStore.sql106
3 files changed, 152 insertions, 0 deletions
diff --git a/OpenSim/Data/MySQL/Resources/001_AssetStore.sql b/OpenSim/Data/MySQL/Resources/001_AssetStore.sql
new file mode 100644
index 0000000..2c750fe
--- /dev/null
+++ b/OpenSim/Data/MySQL/Resources/001_AssetStore.sql
@@ -0,0 +1,11 @@
1CREATE TABLE `assets` (
2 `id` binary(16) NOT NULL,
3 `name` varchar(64) NOT NULL,
4 `description` varchar(64) NOT NULL,
5 `assetType` tinyint(4) NOT NULL,
6 `invType` tinyint(4) NOT NULL,
7 `local` tinyint(1) NOT NULL,
8 `temporary` tinyint(1) NOT NULL,
9 `data` longblob NOT NULL,
10 PRIMARY KEY (`id`)
11) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Rev. 1'; \ No newline at end of file
diff --git a/OpenSim/Data/MySQL/Resources/001_InventoryStore.sql b/OpenSim/Data/MySQL/Resources/001_InventoryStore.sql
new file mode 100644
index 0000000..84701db
--- /dev/null
+++ b/OpenSim/Data/MySQL/Resources/001_InventoryStore.sql
@@ -0,0 +1,35 @@
1CREATE TABLE `inventoryfolders` (
2 `folderID` varchar(36) NOT NULL default '',
3 `agentID` varchar(36) default NULL,
4 `parentFolderID` varchar(36) default NULL,
5 `folderName` varchar(64) default NULL,
6 `type` smallint NOT NULL default 0,
7 `version` int NOT NULL default 0,
8 PRIMARY KEY (`folderID`),
9 KEY `owner` (`agentID`),
10 KEY `parent` (`parentFolderID`)
11) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Rev. 2';
12CREATE TABLE `inventoryitems` (
13 `inventoryID` varchar(36) NOT NULL default '',
14 `assetID` varchar(36) default NULL,
15 `assetType` int(11) default NULL,
16 `parentFolderID` varchar(36) default NULL,
17 `avatarID` varchar(36) default NULL,
18 `inventoryName` varchar(64) default NULL,
19 `inventoryDescription` varchar(128) default NULL,
20 `inventoryNextPermissions` int(10) unsigned default NULL,
21 `inventoryCurrentPermissions` int(10) unsigned default NULL,
22 `invType` int(11) default NULL,
23 `creatorID` varchar(36) default NULL,
24 `inventoryBasePermissions` int(10) unsigned NOT NULL default 0,
25 `inventoryEveryOnePermissions` int(10) unsigned NOT NULL default 0,
26 `salePrice` int(11) NOT NULL default 0,
27 `saleType` tinyint(4) NOT NULL default 0,
28 `creationDate` int(11) NOT NULL default 0,
29 `groupID` varchar(36) NOT NULL default '00000000-0000-0000-0000-000000000000',
30 `groupOwned` tinyint(4) NOT NULL default 0,
31 `flags` int(11) unsigned NOT NULL default 0,
32 PRIMARY KEY (`inventoryID`),
33 KEY `owner` (`avatarID`),
34 KEY `folder` (`parentFolderID`)
35) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Rev. 3';
diff --git a/OpenSim/Data/MySQL/Resources/001_UserStore.sql b/OpenSim/Data/MySQL/Resources/001_UserStore.sql
new file mode 100644
index 0000000..7ab628f
--- /dev/null
+++ b/OpenSim/Data/MySQL/Resources/001_UserStore.sql
@@ -0,0 +1,106 @@
1SET FOREIGN_KEY_CHECKS=0;
2-- ----------------------------
3-- Table structure for agents
4-- ----------------------------
5CREATE TABLE `agents` (
6 `UUID` varchar(36) NOT NULL,
7 `sessionID` varchar(36) NOT NULL,
8 `secureSessionID` varchar(36) NOT NULL,
9 `agentIP` varchar(16) NOT NULL,
10 `agentPort` int(11) NOT NULL,
11 `agentOnline` tinyint(4) NOT NULL,
12 `loginTime` int(11) NOT NULL,
13 `logoutTime` int(11) NOT NULL,
14 `currentRegion` varchar(36) NOT NULL,
15 `currentHandle` bigint(20) unsigned NOT NULL,
16 `currentPos` varchar(64) NOT NULL,
17 PRIMARY KEY (`UUID`),
18 UNIQUE KEY `session` (`sessionID`),
19 UNIQUE KEY `ssession` (`secureSessionID`)
20) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Rev. 1';
21
22-- Create schema avatar_appearance
23--
24
25CREATE TABLE `avatarappearance` (
26 Owner char(36) NOT NULL,
27 Serial int(10) unsigned NOT NULL,
28 Visual_Params blob NOT NULL,
29 Texture blob NOT NULL,
30 Avatar_Height float NOT NULL,
31 Body_Item char(36) NOT NULL,
32 Body_Asset char(36) NOT NULL,
33 Skin_Item char(36) NOT NULL,
34 Skin_Asset char(36) NOT NULL,
35 Hair_Item char(36) NOT NULL,
36 Hair_Asset char(36) NOT NULL,
37 Eyes_Item char(36) NOT NULL,
38 Eyes_Asset char(36) NOT NULL,
39 Shirt_Item char(36) NOT NULL,
40 Shirt_Asset char(36) NOT NULL,
41 Pants_Item char(36) NOT NULL,
42 Pants_Asset char(36) NOT NULL,
43 Shoes_Item char(36) NOT NULL,
44 Shoes_Asset char(36) NOT NULL,
45 Socks_Item char(36) NOT NULL,
46 Socks_Asset char(36) NOT NULL,
47 Jacket_Item char(36) NOT NULL,
48 Jacket_Asset char(36) NOT NULL,
49 Gloves_Item char(36) NOT NULL,
50 Gloves_Asset char(36) NOT NULL,
51 Undershirt_Item char(36) NOT NULL,
52 Undershirt_Asset char(36) NOT NULL,
53 Underpants_Item char(36) NOT NULL,
54 Underpants_Asset char(36) NOT NULL,
55 Skirt_Item char(36) NOT NULL,
56 Skirt_Asset char(36) NOT NULL,
57
58
59 PRIMARY KEY (`Owner`)
60) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Rev.2';
61
62SET FOREIGN_KEY_CHECKS=0;
63-- ----------------------------
64-- Table structure for users
65-- ----------------------------
66CREATE TABLE `userfriends` (
67 `ownerID` VARCHAR(37) NOT NULL,
68 `friendID` VARCHAR(37) NOT NULL,
69 `friendPerms` INT NOT NULL,
70 `datetimestamp` INT NOT NULL,
71 UNIQUE KEY (`ownerID`, `friendID`)
72) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Rev.1';SET FOREIGN_KEY_CHECKS=0;
73-- ----------------------------
74-- Table structure for users
75-- ----------------------------
76CREATE TABLE `users` (
77 `UUID` varchar(36) NOT NULL default '',
78 `username` varchar(32) NOT NULL,
79 `lastname` varchar(32) NOT NULL,
80 `passwordHash` varchar(32) NOT NULL,
81 `passwordSalt` varchar(32) NOT NULL,
82 `homeRegion` bigint(20) unsigned default NULL,
83 `homeLocationX` float default NULL,
84 `homeLocationY` float default NULL,
85 `homeLocationZ` float default NULL,
86 `homeLookAtX` float default NULL,
87 `homeLookAtY` float default NULL,
88 `homeLookAtZ` float default NULL,
89 `created` int(11) NOT NULL,
90 `lastLogin` int(11) NOT NULL,
91 `userInventoryURI` varchar(255) default NULL,
92 `userAssetURI` varchar(255) default NULL,
93 `profileCanDoMask` int(10) unsigned default NULL,
94 `profileWantDoMask` int(10) unsigned default NULL,
95 `profileAboutText` text,
96 `profileFirstText` text,
97 `profileImage` varchar(36) default NULL,
98 `profileFirstImage` varchar(36) default NULL,
99 `webLoginKey` varchar(36) default NULL,
100 PRIMARY KEY (`UUID`),
101 UNIQUE KEY `usernames` (`username`,`lastname`)
102) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Rev. 2';
103
104-- ----------------------------
105-- Records
106-- ----------------------------