add mysql migrations for nhibernate driver

0.6.0-stable
Sean Dague 2008-06-18 21:08:16 +00:00
parent b6667e7224
commit b58dc7fb33
3 changed files with 136 additions and 10 deletions

View File

@ -1,14 +1,15 @@
START TRANSACTION;
create table Assets(
ID varchar(36) not null primary key,
Type int default 0,
InvType int default 0,
Name varchar(64),
Description varchar(64),
Local boolean,
Temporary boolean,
Data blob
);
CREATE TABLE `Assets` (
`ID` char(36) NOT NULL,
`Type` smallint(6) default NULL,
`InvType` smallint(6) default NULL,
`Name` varchar(64) default NULL,
`Description` varchar(64) default NULL,
`Local` tinyint(1) default NULL,
`Temporary` tinyint(1) default NULL,
`Data` longblob,
PRIMARY KEY (`ID`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
COMMIT;

View File

@ -0,0 +1,41 @@
START TRANSACTION;
CREATE TABLE `InventoryFolders` (
`ID` char(36) NOT NULL,
`Type` int(11) default NULL,
`Version` int(11) default NULL,
`ParentID` char(36) default NULL,
`Owner` char(36) default NULL,
`Name` varchar(64) default NULL,
PRIMARY KEY (`ID`),
KEY `folder_owner_id` (`Owner`),
KEY `folder_parent_id` (`ParentID`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
CREATE TABLE `InventoryItems` (
`ID` char(36) NOT NULL,
`InvType` smallint(6) default NULL,
`AssetType` smallint(6) default NULL,
`AssetID` char(36) default NULL,
`Folder` char(36) default NULL,
`Owner` char(36) default NULL,
`Creator` char(36) default NULL,
`Name` varchar(64) default NULL,
`Description` varchar(64) default NULL,
`NextPermissions` int(11) default NULL,
`CurrentPermissions` int(11) default NULL,
`BasePermissions` int(11) default NULL,
`EveryOnePermissions` int(11) default NULL,
`GroupID` char(36) default NULL,
`GroupOwned` tinyint(1) default NULL,
`SalePrice` int(11) default NULL,
`SaleType` smallint(6) default NULL,
`Flags` int(11) default NULL,
`CreationDate` int(11) default NULL,
PRIMARY KEY (`ID`),
KEY `item_group_id` (`GroupID`),
KEY `item_owner_id` (`Owner`),
KEY `item_folder_id` (`Folder`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
COMMIT;

View File

@ -0,0 +1,84 @@
START TRANSACTION;
CREATE TABLE `UserAgents` (
`ProfileID` varchar(255) NOT NULL,
`AgentIP` varchar(24) default NULL,
`AgentPort` int(11) default NULL,
`AgentOnline` tinyint(1) default NULL,
`SessionID` varchar(255) default NULL,
`SecureSessionID` varchar(255) default NULL,
`InitialRegion` varchar(255) default NULL,
`Region` varchar(255) default NULL,
`LoginTime` int(11) default NULL,
`LogoutTime` int(11) default NULL,
`Handle` bigint(20) default NULL,
`PositionX` float default NULL,
`PositionY` float default NULL,
`PositionZ` float default NULL,
PRIMARY KEY (`ProfileID`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
CREATE TABLE `UserProfiles` (
`ID` varchar(255) NOT NULL,
`FirstName` varchar(32) default NULL,
`SurName` varchar(32) default NULL,
`PasswordHash` varchar(32) default NULL,
`PasswordSalt` varchar(32) default NULL,
`WebLoginKey` varchar(255) default NULL,
`HomeRegionX` int(11) default NULL,
`HomeRegionY` int(11) default NULL,
`HomeLocationX` float default NULL,
`HomeLocationY` float default NULL,
`HomeLocationZ` float default NULL,
`HomeLookAtX` float default NULL,
`HomeLookAtY` float default NULL,
`HomeLookAtZ` float default NULL,
`Created` int(11) default NULL,
`LastLogin` int(11) default NULL,
`RootInventoryFolderID` varchar(255) default NULL,
`UserInventoryURI` varchar(255) default NULL,
`UserAssetURI` varchar(255) default NULL,
`Image` varchar(255) default NULL,
`FirstLifeImage` varchar(255) default NULL,
`AboutText` varchar(255) default NULL,
`FirstLifeAboutText` varchar(255) default NULL,
PRIMARY KEY (`ID`),
KEY `user_surname` (`SurName`),
KEY `user_firstname` (`FirstName`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
CREATE TABLE `UserAppearances` (
`Owner` varchar(255) NOT NULL,
`BodyItem` varchar(255) default NULL,
`BodyAsset` varchar(255) default NULL,
`SkinItem` varchar(255) default NULL,
`SkinAsset` varchar(255) default NULL,
`HairItem` varchar(255) default NULL,
`HairAsset` varchar(255) default NULL,
`EyesItem` varchar(255) default NULL,
`EyesAsset` varchar(255) default NULL,
`ShirtItem` varchar(255) default NULL,
`ShirtAsset` varchar(255) default NULL,
`PantsItem` varchar(255) default NULL,
`PantsAsset` varchar(255) default NULL,
`ShoesItem` varchar(255) default NULL,
`ShoesAsset` varchar(255) default NULL,
`SocksItem` varchar(255) default NULL,
`SocksAsset` varchar(255) default NULL,
`JacketItem` varchar(255) default NULL,
`JacketAsset` varchar(255) default NULL,
`GlovesItem` varchar(255) default NULL,
`GlovesAsset` varchar(255) default NULL,
`UnderShirtItem` varchar(255) default NULL,
`UnderShirtAsset` varchar(255) default NULL,
`UnderPantsItem` varchar(255) default NULL,
`UnderPantsAsset` varchar(255) default NULL,
`SkirtItem` varchar(255) default NULL,
`SkirtAsset` varchar(255) default NULL,
`Texture` longblob,
`VisualParams` longblob,
`Serial` int(11) default NULL,
PRIMARY KEY (`Owner`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
COMMIT;