diff options
Diffstat (limited to 'OpenSim/Data/MySQL')
87 files changed, 1435 insertions, 1164 deletions
diff --git a/OpenSim/Data/MySQL/MySQLAssetData.cs b/OpenSim/Data/MySQL/MySQLAssetData.cs index 13f5fa2..fe5152a 100644 --- a/OpenSim/Data/MySQL/MySQLAssetData.cs +++ b/OpenSim/Data/MySQL/MySQLAssetData.cs | |||
@@ -33,6 +33,7 @@ using log4net; | |||
33 | using MySql.Data.MySqlClient; | 33 | using MySql.Data.MySqlClient; |
34 | using OpenMetaverse; | 34 | using OpenMetaverse; |
35 | using OpenSim.Framework; | 35 | using OpenSim.Framework; |
36 | using OpenSim.Data; | ||
36 | 37 | ||
37 | namespace OpenSim.Data.MySQL | 38 | namespace OpenSim.Data.MySQL |
38 | { | 39 | { |
@@ -111,7 +112,7 @@ namespace OpenSim.Data.MySQL | |||
111 | dbcon.Open(); | 112 | dbcon.Open(); |
112 | 113 | ||
113 | using (MySqlCommand cmd = new MySqlCommand( | 114 | using (MySqlCommand cmd = new MySqlCommand( |
114 | "SELECT name, description, assetType, local, temporary, asset_flags, data FROM assets WHERE id=?id", | 115 | "SELECT name, description, assetType, local, temporary, asset_flags, CreatorID, data FROM assets WHERE id=?id", |
115 | dbcon)) | 116 | dbcon)) |
116 | { | 117 | { |
117 | cmd.Parameters.AddWithValue("?id", assetID.ToString()); | 118 | cmd.Parameters.AddWithValue("?id", assetID.ToString()); |
@@ -122,7 +123,7 @@ namespace OpenSim.Data.MySQL | |||
122 | { | 123 | { |
123 | if (dbReader.Read()) | 124 | if (dbReader.Read()) |
124 | { | 125 | { |
125 | asset = new AssetBase(assetID, (string)dbReader["name"], (sbyte)dbReader["assetType"], UUID.Zero.ToString()); | 126 | asset = new AssetBase(assetID, (string)dbReader["name"], (sbyte)dbReader["assetType"], dbReader["CreatorID"].ToString()); |
126 | asset.Data = (byte[])dbReader["data"]; | 127 | asset.Data = (byte[])dbReader["data"]; |
127 | asset.Description = (string)dbReader["description"]; | 128 | asset.Description = (string)dbReader["description"]; |
128 | 129 | ||
@@ -162,8 +163,8 @@ namespace OpenSim.Data.MySQL | |||
162 | 163 | ||
163 | MySqlCommand cmd = | 164 | MySqlCommand cmd = |
164 | new MySqlCommand( | 165 | new MySqlCommand( |
165 | "replace INTO assets(id, name, description, assetType, local, temporary, create_time, access_time, asset_flags, data)" + | 166 | "replace INTO assets(id, name, description, assetType, local, temporary, create_time, access_time, asset_flags, CreatorID, data)" + |
166 | "VALUES(?id, ?name, ?description, ?assetType, ?local, ?temporary, ?create_time, ?access_time, ?asset_flags, ?data)", | 167 | "VALUES(?id, ?name, ?description, ?assetType, ?local, ?temporary, ?create_time, ?access_time, ?asset_flags, ?CreatorID, ?data)", |
167 | dbcon); | 168 | dbcon); |
168 | 169 | ||
169 | string assetName = asset.Name; | 170 | string assetName = asset.Name; |
@@ -195,6 +196,7 @@ namespace OpenSim.Data.MySQL | |||
195 | cmd.Parameters.AddWithValue("?temporary", asset.Temporary); | 196 | cmd.Parameters.AddWithValue("?temporary", asset.Temporary); |
196 | cmd.Parameters.AddWithValue("?create_time", now); | 197 | cmd.Parameters.AddWithValue("?create_time", now); |
197 | cmd.Parameters.AddWithValue("?access_time", now); | 198 | cmd.Parameters.AddWithValue("?access_time", now); |
199 | cmd.Parameters.AddWithValue("?CreatorID", asset.Metadata.CreatorID); | ||
198 | cmd.Parameters.AddWithValue("?asset_flags", (int)asset.Flags); | 200 | cmd.Parameters.AddWithValue("?asset_flags", (int)asset.Flags); |
199 | cmd.Parameters.AddWithValue("?data", asset.Data); | 201 | cmd.Parameters.AddWithValue("?data", asset.Data); |
200 | cmd.ExecuteNonQuery(); | 202 | cmd.ExecuteNonQuery(); |
@@ -304,7 +306,7 @@ namespace OpenSim.Data.MySQL | |||
304 | using (MySqlConnection dbcon = new MySqlConnection(m_connectionString)) | 306 | using (MySqlConnection dbcon = new MySqlConnection(m_connectionString)) |
305 | { | 307 | { |
306 | dbcon.Open(); | 308 | dbcon.Open(); |
307 | MySqlCommand cmd = new MySqlCommand("SELECT name,description,assetType,temporary,id,asset_flags FROM assets LIMIT ?start, ?count", dbcon); | 309 | MySqlCommand cmd = new MySqlCommand("SELECT name,description,assetType,temporary,id,asset_flags,CreatorID FROM assets LIMIT ?start, ?count", dbcon); |
308 | cmd.Parameters.AddWithValue("?start", start); | 310 | cmd.Parameters.AddWithValue("?start", start); |
309 | cmd.Parameters.AddWithValue("?count", count); | 311 | cmd.Parameters.AddWithValue("?count", count); |
310 | 312 | ||
@@ -320,7 +322,8 @@ namespace OpenSim.Data.MySQL | |||
320 | metadata.Type = (sbyte)dbReader["assetType"]; | 322 | metadata.Type = (sbyte)dbReader["assetType"]; |
321 | metadata.Temporary = Convert.ToBoolean(dbReader["temporary"]); // Not sure if this is correct. | 323 | metadata.Temporary = Convert.ToBoolean(dbReader["temporary"]); // Not sure if this is correct. |
322 | metadata.Flags = (AssetFlags)Convert.ToInt32(dbReader["asset_flags"]); | 324 | metadata.Flags = (AssetFlags)Convert.ToInt32(dbReader["asset_flags"]); |
323 | metadata.FullID = new UUID((string)dbReader["id"]); | 325 | metadata.FullID = DBGuid.FromDB(dbReader["id"]); |
326 | metadata.CreatorID = dbReader["CreatorID"].ToString(); | ||
324 | 327 | ||
325 | // Current SHA1s are not stored/computed. | 328 | // Current SHA1s are not stored/computed. |
326 | metadata.SHA1 = new byte[] { }; | 329 | metadata.SHA1 = new byte[] { }; |
diff --git a/OpenSim/Data/MySQL/MySQLEstateData.cs b/OpenSim/Data/MySQL/MySQLEstateData.cs index 08e2144..9158f7a 100644 --- a/OpenSim/Data/MySQL/MySQLEstateData.cs +++ b/OpenSim/Data/MySQL/MySQLEstateData.cs | |||
@@ -34,6 +34,7 @@ using MySql.Data.MySqlClient; | |||
34 | using OpenMetaverse; | 34 | using OpenMetaverse; |
35 | using OpenSim.Framework; | 35 | using OpenSim.Framework; |
36 | using OpenSim.Region.Framework.Interfaces; | 36 | using OpenSim.Region.Framework.Interfaces; |
37 | using OpenSim.Data; | ||
37 | 38 | ||
38 | namespace OpenSim.Data.MySQL | 39 | namespace OpenSim.Data.MySQL |
39 | { | 40 | { |
@@ -156,20 +157,13 @@ namespace OpenSim.Data.MySQL | |||
156 | 157 | ||
157 | foreach (string name in FieldList) | 158 | foreach (string name in FieldList) |
158 | { | 159 | { |
159 | if (m_FieldMap[name].GetValue(es) is bool) | 160 | if (m_FieldMap[name].FieldType == typeof(bool)) |
160 | { | 161 | { |
161 | int v = Convert.ToInt32(r[name]); | 162 | m_FieldMap[name].SetValue(es, Convert.ToInt32(r[name]) != 0); |
162 | if (v != 0) | ||
163 | m_FieldMap[name].SetValue(es, true); | ||
164 | else | ||
165 | m_FieldMap[name].SetValue(es, false); | ||
166 | } | 163 | } |
167 | else if (m_FieldMap[name].GetValue(es) is UUID) | 164 | else if (m_FieldMap[name].FieldType == typeof(UUID)) |
168 | { | 165 | { |
169 | UUID uuid = UUID.Zero; | 166 | m_FieldMap[name].SetValue(es, DBGuid.FromDB(r[name])); |
170 | |||
171 | UUID.TryParse(r[name].ToString(), out uuid); | ||
172 | m_FieldMap[name].SetValue(es, uuid); | ||
173 | } | 167 | } |
174 | else | 168 | else |
175 | { | 169 | { |
@@ -385,11 +379,7 @@ namespace OpenSim.Data.MySQL | |||
385 | while (r.Read()) | 379 | while (r.Read()) |
386 | { | 380 | { |
387 | // EstateBan eb = new EstateBan(); | 381 | // EstateBan eb = new EstateBan(); |
388 | 382 | uuids.Add(DBGuid.FromDB(r["uuid"])); | |
389 | UUID uuid = new UUID(); | ||
390 | UUID.TryParse(r["uuid"].ToString(), out uuid); | ||
391 | |||
392 | uuids.Add(uuid); | ||
393 | } | 383 | } |
394 | } | 384 | } |
395 | } | 385 | } |
@@ -490,7 +480,7 @@ namespace OpenSim.Data.MySQL | |||
490 | using (IDataReader reader = cmd.ExecuteReader()) | 480 | using (IDataReader reader = cmd.ExecuteReader()) |
491 | { | 481 | { |
492 | while(reader.Read()) | 482 | while(reader.Read()) |
493 | result.Add(new UUID(reader["RegionID"].ToString())); | 483 | result.Add(DBGuid.FromDB(reader["RegionID"])); |
494 | reader.Close(); | 484 | reader.Close(); |
495 | } | 485 | } |
496 | } | 486 | } |
diff --git a/OpenSim/Data/MySQL/MySQLGenericTableHandler.cs b/OpenSim/Data/MySQL/MySQLGenericTableHandler.cs index 1253e0b..6cbb2ee 100644 --- a/OpenSim/Data/MySQL/MySQLGenericTableHandler.cs +++ b/OpenSim/Data/MySQL/MySQLGenericTableHandler.cs | |||
@@ -148,19 +148,16 @@ namespace OpenSim.Data.MySQL | |||
148 | 148 | ||
149 | foreach (string name in m_Fields.Keys) | 149 | foreach (string name in m_Fields.Keys) |
150 | { | 150 | { |
151 | if (m_Fields[name].GetValue(row) is bool) | 151 | if (m_Fields[name].FieldType == typeof(bool)) |
152 | { | 152 | { |
153 | int v = Convert.ToInt32(reader[name]); | 153 | int v = Convert.ToInt32(reader[name]); |
154 | m_Fields[name].SetValue(row, v != 0 ? true : false); | 154 | m_Fields[name].SetValue(row, v != 0 ? true : false); |
155 | } | 155 | } |
156 | else if (m_Fields[name].GetValue(row) is UUID) | 156 | else if (m_Fields[name].FieldType == typeof(UUID)) |
157 | { | 157 | { |
158 | UUID uuid = UUID.Zero; | 158 | m_Fields[name].SetValue(row, DBGuid.FromDB(reader[name])); |
159 | |||
160 | UUID.TryParse(reader[name].ToString(), out uuid); | ||
161 | m_Fields[name].SetValue(row, uuid); | ||
162 | } | 159 | } |
163 | else if (m_Fields[name].GetValue(row) is int) | 160 | else if (m_Fields[name].FieldType == typeof(int)) |
164 | { | 161 | { |
165 | int v = Convert.ToInt32(reader[name]); | 162 | int v = Convert.ToInt32(reader[name]); |
166 | m_Fields[name].SetValue(row, v); | 163 | m_Fields[name].SetValue(row, v); |
diff --git a/OpenSim/Data/MySQL/MySQLInventoryData.cs b/OpenSim/Data/MySQL/MySQLInventoryData.cs index e0e9b9c..0aea30f 100644 --- a/OpenSim/Data/MySQL/MySQLInventoryData.cs +++ b/OpenSim/Data/MySQL/MySQLInventoryData.cs | |||
@@ -32,6 +32,7 @@ using log4net; | |||
32 | using MySql.Data.MySqlClient; | 32 | using MySql.Data.MySqlClient; |
33 | using OpenMetaverse; | 33 | using OpenMetaverse; |
34 | using OpenSim.Framework; | 34 | using OpenSim.Framework; |
35 | using OpenSim.Data; | ||
35 | 36 | ||
36 | namespace OpenSim.Data.MySQL | 37 | namespace OpenSim.Data.MySQL |
37 | { | 38 | { |
@@ -285,31 +286,23 @@ namespace OpenSim.Data.MySQL | |||
285 | InventoryItemBase item = new InventoryItemBase(); | 286 | InventoryItemBase item = new InventoryItemBase(); |
286 | 287 | ||
287 | // TODO: this is to handle a case where NULLs creep in there, which we are not sure is endemic to the system, or legacy. It would be nice to live fix these. | 288 | // TODO: this is to handle a case where NULLs creep in there, which we are not sure is endemic to the system, or legacy. It would be nice to live fix these. |
288 | if (reader["creatorID"] == null) | 289 | // ( DBGuid.FromDB() reads db NULLs as well, returns UUID.Zero ) |
289 | { | 290 | item.CreatorId = reader["creatorID"].ToString(); |
290 | item.CreatorId = UUID.Zero.ToString(); | ||
291 | } | ||
292 | else | ||
293 | { | ||
294 | item.CreatorId = (string)reader["creatorID"]; | ||
295 | } | ||
296 | 291 | ||
297 | // Be a bit safer in parsing these because the | 292 | // Be a bit safer in parsing these because the |
298 | // database doesn't enforce them to be not null, and | 293 | // database doesn't enforce them to be not null, and |
299 | // the inventory still works if these are weird in the | 294 | // the inventory still works if these are weird in the |
300 | // db | 295 | // db |
301 | UUID Owner = UUID.Zero; | 296 | |
302 | UUID GroupID = UUID.Zero; | 297 | // (Empty is Ok, but "weird" will throw!) |
303 | UUID.TryParse((string)reader["avatarID"], out Owner); | 298 | item.Owner = DBGuid.FromDB(reader["avatarID"]); |
304 | UUID.TryParse((string)reader["groupID"], out GroupID); | 299 | item.GroupID = DBGuid.FromDB(reader["groupID"]); |
305 | item.Owner = Owner; | ||
306 | item.GroupID = GroupID; | ||
307 | 300 | ||
308 | // Rest of the parsing. If these UUID's fail, we're dead anyway | 301 | // Rest of the parsing. If these UUID's fail, we're dead anyway |
309 | item.ID = new UUID((string) reader["inventoryID"]); | 302 | item.ID = DBGuid.FromDB(reader["inventoryID"]); |
310 | item.AssetID = new UUID((string) reader["assetID"]); | 303 | item.AssetID = DBGuid.FromDB(reader["assetID"]); |
311 | item.AssetType = (int) reader["assetType"]; | 304 | item.AssetType = (int) reader["assetType"]; |
312 | item.Folder = new UUID((string) reader["parentFolderID"]); | 305 | item.Folder = DBGuid.FromDB(reader["parentFolderID"]); |
313 | item.Name = (string)(reader["inventoryName"] ?? String.Empty); | 306 | item.Name = (string)(reader["inventoryName"] ?? String.Empty); |
314 | item.Description = (string)(reader["inventoryDescription"] ?? String.Empty); | 307 | item.Description = (string)(reader["inventoryDescription"] ?? String.Empty); |
315 | item.NextPermissions = (uint) reader["inventoryNextPermissions"]; | 308 | item.NextPermissions = (uint) reader["inventoryNextPermissions"]; |
@@ -382,9 +375,9 @@ namespace OpenSim.Data.MySQL | |||
382 | try | 375 | try |
383 | { | 376 | { |
384 | InventoryFolderBase folder = new InventoryFolderBase(); | 377 | InventoryFolderBase folder = new InventoryFolderBase(); |
385 | folder.Owner = new UUID((string) reader["agentID"]); | 378 | folder.Owner = DBGuid.FromDB(reader["agentID"]); |
386 | folder.ParentID = new UUID((string) reader["parentFolderID"]); | 379 | folder.ParentID = DBGuid.FromDB(reader["parentFolderID"]); |
387 | folder.ID = new UUID((string) reader["folderID"]); | 380 | folder.ID = DBGuid.FromDB(reader["folderID"]); |
388 | folder.Name = (string) reader["folderName"]; | 381 | folder.Name = (string) reader["folderName"]; |
389 | folder.Type = (short) reader["type"]; | 382 | folder.Type = (short) reader["type"]; |
390 | folder.Version = (ushort) ((int) reader["version"]); | 383 | folder.Version = (ushort) ((int) reader["version"]); |
diff --git a/OpenSim/Data/MySQL/MySQLLegacyRegionData.cs b/OpenSim/Data/MySQL/MySQLLegacyRegionData.cs index 07371e7..bfeae12 100644 --- a/OpenSim/Data/MySQL/MySQLLegacyRegionData.cs +++ b/OpenSim/Data/MySQL/MySQLLegacyRegionData.cs | |||
@@ -38,6 +38,7 @@ using OpenMetaverse; | |||
38 | using OpenSim.Framework; | 38 | using OpenSim.Framework; |
39 | using OpenSim.Region.Framework.Interfaces; | 39 | using OpenSim.Region.Framework.Interfaces; |
40 | using OpenSim.Region.Framework.Scenes; | 40 | using OpenSim.Region.Framework.Scenes; |
41 | using OpenSim.Data; | ||
41 | 42 | ||
42 | namespace OpenSim.Data.MySQL | 43 | namespace OpenSim.Data.MySQL |
43 | { | 44 | { |
@@ -269,7 +270,7 @@ namespace OpenSim.Data.MySQL | |||
269 | using (IDataReader reader = ExecuteReader(cmd)) | 270 | using (IDataReader reader = ExecuteReader(cmd)) |
270 | { | 271 | { |
271 | while (reader.Read()) | 272 | while (reader.Read()) |
272 | uuids.Add(new UUID(reader["UUID"].ToString())); | 273 | uuids.Add(DBGuid.FromDB(reader["UUID"].ToString())); |
273 | } | 274 | } |
274 | 275 | ||
275 | // delete the main prims | 276 | // delete the main prims |
@@ -422,7 +423,7 @@ namespace OpenSim.Data.MySQL | |||
422 | else | 423 | else |
423 | prim.Shape = BuildShape(reader); | 424 | prim.Shape = BuildShape(reader); |
424 | 425 | ||
425 | UUID parentID = new UUID(reader["SceneGroupID"].ToString()); | 426 | UUID parentID = DBGuid.FromDB(reader["SceneGroupID"].ToString()); |
426 | if (parentID != prim.UUID) | 427 | if (parentID != prim.UUID) |
427 | prim.ParentUUID = parentID; | 428 | prim.ParentUUID = parentID; |
428 | 429 | ||
@@ -500,7 +501,7 @@ namespace OpenSim.Data.MySQL | |||
500 | { | 501 | { |
501 | if (!(itemReader["primID"] is DBNull)) | 502 | if (!(itemReader["primID"] is DBNull)) |
502 | { | 503 | { |
503 | UUID primID = new UUID(itemReader["primID"].ToString()); | 504 | UUID primID = DBGuid.FromDB(itemReader["primID"].ToString()); |
504 | if (prims.ContainsKey(primID)) | 505 | if (prims.ContainsKey(primID)) |
505 | primsWithInventory.Add(prims[primID]); | 506 | primsWithInventory.Add(prims[primID]); |
506 | } | 507 | } |
@@ -738,7 +739,7 @@ namespace OpenSim.Data.MySQL | |||
738 | } | 739 | } |
739 | else | 740 | else |
740 | { | 741 | { |
741 | UUID.TryParse(result["region_id"].ToString(), out nWP.regionID); | 742 | nWP.regionID = DBGuid.FromDB(result["region_id"]); |
742 | nWP.waterColor.X = Convert.ToSingle(result["water_color_r"]); | 743 | nWP.waterColor.X = Convert.ToSingle(result["water_color_r"]); |
743 | nWP.waterColor.Y = Convert.ToSingle(result["water_color_g"]); | 744 | nWP.waterColor.Y = Convert.ToSingle(result["water_color_g"]); |
744 | nWP.waterColor.Z = Convert.ToSingle(result["water_color_b"]); | 745 | nWP.waterColor.Z = Convert.ToSingle(result["water_color_b"]); |
@@ -1055,7 +1056,14 @@ namespace OpenSim.Data.MySQL | |||
1055 | private SceneObjectPart BuildPrim(IDataReader row) | 1056 | private SceneObjectPart BuildPrim(IDataReader row) |
1056 | { | 1057 | { |
1057 | SceneObjectPart prim = new SceneObjectPart(); | 1058 | SceneObjectPart prim = new SceneObjectPart(); |
1058 | prim.UUID = new UUID((string)row["UUID"]); | 1059 | |
1060 | // depending on the MySQL connector version, CHAR(36) may be already converted to Guid! | ||
1061 | prim.UUID = DBGuid.FromDB(row["UUID"]); | ||
1062 | prim.CreatorID = DBGuid.FromDB(row["CreatorID"]); | ||
1063 | prim.OwnerID = DBGuid.FromDB(row["OwnerID"]); | ||
1064 | prim.GroupID = DBGuid.FromDB(row["GroupID"]); | ||
1065 | prim.LastOwnerID = DBGuid.FromDB(row["LastOwnerID"]); | ||
1066 | |||
1059 | // explicit conversion of integers is required, which sort | 1067 | // explicit conversion of integers is required, which sort |
1060 | // of sucks. No idea if there is a shortcut here or not. | 1068 | // of sucks. No idea if there is a shortcut here or not. |
1061 | prim.CreationDate = (int)row["CreationDate"]; | 1069 | prim.CreationDate = (int)row["CreationDate"]; |
@@ -1074,15 +1082,12 @@ namespace OpenSim.Data.MySQL | |||
1074 | prim.TouchName = (string)row["TouchName"]; | 1082 | prim.TouchName = (string)row["TouchName"]; |
1075 | // Permissions | 1083 | // Permissions |
1076 | prim.ObjectFlags = (uint)(int)row["ObjectFlags"]; | 1084 | prim.ObjectFlags = (uint)(int)row["ObjectFlags"]; |
1077 | prim.CreatorID = new UUID((string)row["CreatorID"]); | ||
1078 | prim.OwnerID = new UUID((string)row["OwnerID"]); | ||
1079 | prim.GroupID = new UUID((string)row["GroupID"]); | ||
1080 | prim.LastOwnerID = new UUID((string)row["LastOwnerID"]); | ||
1081 | prim.OwnerMask = (uint)(int)row["OwnerMask"]; | 1085 | prim.OwnerMask = (uint)(int)row["OwnerMask"]; |
1082 | prim.NextOwnerMask = (uint)(int)row["NextOwnerMask"]; | 1086 | prim.NextOwnerMask = (uint)(int)row["NextOwnerMask"]; |
1083 | prim.GroupMask = (uint)(int)row["GroupMask"]; | 1087 | prim.GroupMask = (uint)(int)row["GroupMask"]; |
1084 | prim.EveryoneMask = (uint)(int)row["EveryoneMask"]; | 1088 | prim.EveryoneMask = (uint)(int)row["EveryoneMask"]; |
1085 | prim.BaseMask = (uint)(int)row["BaseMask"]; | 1089 | prim.BaseMask = (uint)(int)row["BaseMask"]; |
1090 | |||
1086 | // Vectors | 1091 | // Vectors |
1087 | prim.OffsetPosition = new Vector3( | 1092 | prim.OffsetPosition = new Vector3( |
1088 | (float)(double)row["PositionX"], | 1093 | (float)(double)row["PositionX"], |
@@ -1134,7 +1139,7 @@ namespace OpenSim.Data.MySQL | |||
1134 | prim.PayPrice[3] = (int)row["PayButton3"]; | 1139 | prim.PayPrice[3] = (int)row["PayButton3"]; |
1135 | prim.PayPrice[4] = (int)row["PayButton4"]; | 1140 | prim.PayPrice[4] = (int)row["PayButton4"]; |
1136 | 1141 | ||
1137 | prim.Sound = new UUID(row["LoopedSound"].ToString()); | 1142 | prim.Sound = DBGuid.FromDB(row["LoopedSound"].ToString()); |
1138 | prim.SoundGain = (float)(double)row["LoopedSoundGain"]; | 1143 | prim.SoundGain = (float)(double)row["LoopedSoundGain"]; |
1139 | prim.SoundFlags = 1; // If it's persisted at all, it's looped | 1144 | prim.SoundFlags = 1; // If it's persisted at all, it's looped |
1140 | 1145 | ||
@@ -1161,16 +1166,10 @@ namespace OpenSim.Data.MySQL | |||
1161 | (float)(double)row["CameraAtOffsetZ"] | 1166 | (float)(double)row["CameraAtOffsetZ"] |
1162 | )); | 1167 | )); |
1163 | 1168 | ||
1164 | if ((sbyte)row["ForceMouselook"] != 0) | 1169 | prim.SetForceMouselook((sbyte)row["ForceMouselook"] != 0); |
1165 | prim.SetForceMouselook(true); | ||
1166 | |||
1167 | prim.ScriptAccessPin = (int)row["ScriptAccessPin"]; | 1170 | prim.ScriptAccessPin = (int)row["ScriptAccessPin"]; |
1168 | 1171 | prim.AllowedDrop = ((sbyte)row["AllowedDrop"] != 0); | |
1169 | if ((sbyte)row["AllowedDrop"] != 0) | 1172 | prim.DIE_AT_EDGE = ((sbyte)row["DieAtEdge"] != 0); |
1170 | prim.AllowedDrop = true; | ||
1171 | |||
1172 | if ((sbyte)row["DieAtEdge"] != 0) | ||
1173 | prim.DIE_AT_EDGE = true; | ||
1174 | 1173 | ||
1175 | prim.SalePrice = (int)row["SalePrice"]; | 1174 | prim.SalePrice = (int)row["SalePrice"]; |
1176 | prim.ObjectSaleType = unchecked((byte)(sbyte)row["SaleType"]); | 1175 | prim.ObjectSaleType = unchecked((byte)(sbyte)row["SaleType"]); |
@@ -1180,11 +1179,10 @@ namespace OpenSim.Data.MySQL | |||
1180 | if (!(row["ClickAction"] is DBNull)) | 1179 | if (!(row["ClickAction"] is DBNull)) |
1181 | prim.ClickAction = unchecked((byte)(sbyte)row["ClickAction"]); | 1180 | prim.ClickAction = unchecked((byte)(sbyte)row["ClickAction"]); |
1182 | 1181 | ||
1183 | prim.CollisionSound = new UUID(row["CollisionSound"].ToString()); | 1182 | prim.CollisionSound = DBGuid.FromDB(row["CollisionSound"]); |
1184 | prim.CollisionSoundVolume = (float)(double)row["CollisionSoundVolume"]; | 1183 | prim.CollisionSoundVolume = (float)(double)row["CollisionSoundVolume"]; |
1185 | 1184 | ||
1186 | if ((sbyte)row["PassTouches"] != 0) | 1185 | prim.PassTouches = ((sbyte)row["PassTouches"] != 0); |
1187 | prim.PassTouches = true; | ||
1188 | prim.LinkNum = (int)row["LinkNumber"]; | 1186 | prim.LinkNum = (int)row["LinkNumber"]; |
1189 | 1187 | ||
1190 | return prim; | 1188 | return prim; |
@@ -1200,10 +1198,10 @@ namespace OpenSim.Data.MySQL | |||
1200 | { | 1198 | { |
1201 | TaskInventoryItem taskItem = new TaskInventoryItem(); | 1199 | TaskInventoryItem taskItem = new TaskInventoryItem(); |
1202 | 1200 | ||
1203 | taskItem.ItemID = new UUID((String)row["itemID"]); | 1201 | taskItem.ItemID = DBGuid.FromDB(row["itemID"]); |
1204 | taskItem.ParentPartID = new UUID((String)row["primID"]); | 1202 | taskItem.ParentPartID = DBGuid.FromDB(row["primID"]); |
1205 | taskItem.AssetID = new UUID((String)row["assetID"]); | 1203 | taskItem.AssetID = DBGuid.FromDB(row["assetID"]); |
1206 | taskItem.ParentID = new UUID((String)row["parentFolderID"]); | 1204 | taskItem.ParentID = DBGuid.FromDB(row["parentFolderID"]); |
1207 | 1205 | ||
1208 | taskItem.InvType = Convert.ToInt32(row["invType"]); | 1206 | taskItem.InvType = Convert.ToInt32(row["invType"]); |
1209 | taskItem.Type = Convert.ToInt32(row["assetType"]); | 1207 | taskItem.Type = Convert.ToInt32(row["assetType"]); |
@@ -1211,10 +1209,10 @@ namespace OpenSim.Data.MySQL | |||
1211 | taskItem.Name = (String)row["name"]; | 1209 | taskItem.Name = (String)row["name"]; |
1212 | taskItem.Description = (String)row["description"]; | 1210 | taskItem.Description = (String)row["description"]; |
1213 | taskItem.CreationDate = Convert.ToUInt32(row["creationDate"]); | 1211 | taskItem.CreationDate = Convert.ToUInt32(row["creationDate"]); |
1214 | taskItem.CreatorID = new UUID((String)row["creatorID"]); | 1212 | taskItem.CreatorID = DBGuid.FromDB(row["creatorID"]); |
1215 | taskItem.OwnerID = new UUID((String)row["ownerID"]); | 1213 | taskItem.OwnerID = DBGuid.FromDB(row["ownerID"]); |
1216 | taskItem.LastOwnerID = new UUID((String)row["lastOwnerID"]); | 1214 | taskItem.LastOwnerID = DBGuid.FromDB(row["lastOwnerID"]); |
1217 | taskItem.GroupID = new UUID((String)row["groupID"]); | 1215 | taskItem.GroupID = DBGuid.FromDB(row["groupID"]); |
1218 | 1216 | ||
1219 | taskItem.NextPermissions = Convert.ToUInt32(row["nextPermissions"]); | 1217 | taskItem.NextPermissions = Convert.ToUInt32(row["nextPermissions"]); |
1220 | taskItem.CurrentPermissions = Convert.ToUInt32(row["currentPermissions"]); | 1218 | taskItem.CurrentPermissions = Convert.ToUInt32(row["currentPermissions"]); |
@@ -1230,7 +1228,7 @@ namespace OpenSim.Data.MySQL | |||
1230 | { | 1228 | { |
1231 | RegionSettings newSettings = new RegionSettings(); | 1229 | RegionSettings newSettings = new RegionSettings(); |
1232 | 1230 | ||
1233 | newSettings.RegionUUID = new UUID((string) row["regionUUID"]); | 1231 | newSettings.RegionUUID = DBGuid.FromDB(row["regionUUID"]); |
1234 | newSettings.BlockTerraform = Convert.ToBoolean(row["block_terraform"]); | 1232 | newSettings.BlockTerraform = Convert.ToBoolean(row["block_terraform"]); |
1235 | newSettings.AllowDamage = Convert.ToBoolean(row["allow_damage"]); | 1233 | newSettings.AllowDamage = Convert.ToBoolean(row["allow_damage"]); |
1236 | newSettings.BlockFly = Convert.ToBoolean(row["block_fly"]); | 1234 | newSettings.BlockFly = Convert.ToBoolean(row["block_fly"]); |
@@ -1244,10 +1242,10 @@ namespace OpenSim.Data.MySQL | |||
1244 | newSettings.DisableScripts = Convert.ToBoolean(row["disable_scripts"]); | 1242 | newSettings.DisableScripts = Convert.ToBoolean(row["disable_scripts"]); |
1245 | newSettings.DisableCollisions = Convert.ToBoolean(row["disable_collisions"]); | 1243 | newSettings.DisableCollisions = Convert.ToBoolean(row["disable_collisions"]); |
1246 | newSettings.DisablePhysics = Convert.ToBoolean(row["disable_physics"]); | 1244 | newSettings.DisablePhysics = Convert.ToBoolean(row["disable_physics"]); |
1247 | newSettings.TerrainTexture1 = new UUID((String) row["terrain_texture_1"]); | 1245 | newSettings.TerrainTexture1 = DBGuid.FromDB(row["terrain_texture_1"]); |
1248 | newSettings.TerrainTexture2 = new UUID((String) row["terrain_texture_2"]); | 1246 | newSettings.TerrainTexture2 = DBGuid.FromDB(row["terrain_texture_2"]); |
1249 | newSettings.TerrainTexture3 = new UUID((String) row["terrain_texture_3"]); | 1247 | newSettings.TerrainTexture3 = DBGuid.FromDB(row["terrain_texture_3"]); |
1250 | newSettings.TerrainTexture4 = new UUID((String) row["terrain_texture_4"]); | 1248 | newSettings.TerrainTexture4 = DBGuid.FromDB(row["terrain_texture_4"]); |
1251 | newSettings.Elevation1NW = Convert.ToDouble(row["elevation_1_nw"]); | 1249 | newSettings.Elevation1NW = Convert.ToDouble(row["elevation_1_nw"]); |
1252 | newSettings.Elevation2NW = Convert.ToDouble(row["elevation_2_nw"]); | 1250 | newSettings.Elevation2NW = Convert.ToDouble(row["elevation_2_nw"]); |
1253 | newSettings.Elevation1NE = Convert.ToDouble(row["elevation_1_ne"]); | 1251 | newSettings.Elevation1NE = Convert.ToDouble(row["elevation_1_ne"]); |
@@ -1268,7 +1266,7 @@ namespace OpenSim.Data.MySQL | |||
1268 | ); | 1266 | ); |
1269 | newSettings.FixedSun = Convert.ToBoolean(row["fixed_sun"]); | 1267 | newSettings.FixedSun = Convert.ToBoolean(row["fixed_sun"]); |
1270 | newSettings.SunPosition = Convert.ToDouble(row["sun_position"]); | 1268 | newSettings.SunPosition = Convert.ToDouble(row["sun_position"]); |
1271 | newSettings.Covenant = new UUID((String) row["covenant"]); | 1269 | newSettings.Covenant = DBGuid.FromDB(row["covenant"]); |
1272 | 1270 | ||
1273 | newSettings.LoadedCreationDateTime = Convert.ToInt32(row["loaded_creation_datetime"]); | 1271 | newSettings.LoadedCreationDateTime = Convert.ToInt32(row["loaded_creation_datetime"]); |
1274 | 1272 | ||
@@ -1277,7 +1275,7 @@ namespace OpenSim.Data.MySQL | |||
1277 | else | 1275 | else |
1278 | newSettings.LoadedCreationID = (String) row["loaded_creation_id"]; | 1276 | newSettings.LoadedCreationID = (String) row["loaded_creation_id"]; |
1279 | 1277 | ||
1280 | newSettings.TerrainImageID = new UUID((String)row["map_tile_ID"]); | 1278 | newSettings.TerrainImageID = DBGuid.FromDB(row["map_tile_ID"]); |
1281 | 1279 | ||
1282 | return newSettings; | 1280 | return newSettings; |
1283 | } | 1281 | } |
@@ -1291,7 +1289,7 @@ namespace OpenSim.Data.MySQL | |||
1291 | { | 1289 | { |
1292 | LandData newData = new LandData(); | 1290 | LandData newData = new LandData(); |
1293 | 1291 | ||
1294 | newData.GlobalID = new UUID((String) row["UUID"]); | 1292 | newData.GlobalID = DBGuid.FromDB(row["UUID"]); |
1295 | newData.LocalID = Convert.ToInt32(row["LocalLandID"]); | 1293 | newData.LocalID = Convert.ToInt32(row["LocalLandID"]); |
1296 | 1294 | ||
1297 | // Bitmap is a byte[512] | 1295 | // Bitmap is a byte[512] |
@@ -1299,7 +1297,7 @@ namespace OpenSim.Data.MySQL | |||
1299 | 1297 | ||
1300 | newData.Name = (String) row["Name"]; | 1298 | newData.Name = (String) row["Name"]; |
1301 | newData.Description = (String) row["Description"]; | 1299 | newData.Description = (String) row["Description"]; |
1302 | newData.OwnerID = new UUID((String)row["OwnerUUID"]); | 1300 | newData.OwnerID = DBGuid.FromDB(row["OwnerUUID"]); |
1303 | newData.IsGroupOwned = Convert.ToBoolean(row["IsGroupOwned"]); | 1301 | newData.IsGroupOwned = Convert.ToBoolean(row["IsGroupOwned"]); |
1304 | newData.Area = Convert.ToInt32(row["Area"]); | 1302 | newData.Area = Convert.ToInt32(row["Area"]); |
1305 | newData.AuctionID = Convert.ToUInt32(row["AuctionID"]); //Unimplemented | 1303 | newData.AuctionID = Convert.ToUInt32(row["AuctionID"]); //Unimplemented |
@@ -1307,14 +1305,14 @@ namespace OpenSim.Data.MySQL | |||
1307 | //Enum libsecondlife.Parcel.ParcelCategory | 1305 | //Enum libsecondlife.Parcel.ParcelCategory |
1308 | newData.ClaimDate = Convert.ToInt32(row["ClaimDate"]); | 1306 | newData.ClaimDate = Convert.ToInt32(row["ClaimDate"]); |
1309 | newData.ClaimPrice = Convert.ToInt32(row["ClaimPrice"]); | 1307 | newData.ClaimPrice = Convert.ToInt32(row["ClaimPrice"]); |
1310 | newData.GroupID = new UUID((String) row["GroupUUID"]); | 1308 | newData.GroupID = DBGuid.FromDB(row["GroupUUID"]); |
1311 | newData.SalePrice = Convert.ToInt32(row["SalePrice"]); | 1309 | newData.SalePrice = Convert.ToInt32(row["SalePrice"]); |
1312 | newData.Status = (ParcelStatus) Convert.ToInt32(row["LandStatus"]); | 1310 | newData.Status = (ParcelStatus) Convert.ToInt32(row["LandStatus"]); |
1313 | //Enum. libsecondlife.Parcel.ParcelStatus | 1311 | //Enum. libsecondlife.Parcel.ParcelStatus |
1314 | newData.Flags = Convert.ToUInt32(row["LandFlags"]); | 1312 | newData.Flags = Convert.ToUInt32(row["LandFlags"]); |
1315 | newData.LandingType = Convert.ToByte(row["LandingType"]); | 1313 | newData.LandingType = Convert.ToByte(row["LandingType"]); |
1316 | newData.MediaAutoScale = Convert.ToByte(row["MediaAutoScale"]); | 1314 | newData.MediaAutoScale = Convert.ToByte(row["MediaAutoScale"]); |
1317 | newData.MediaID = new UUID((String) row["MediaTextureUUID"]); | 1315 | newData.MediaID = DBGuid.FromDB(row["MediaTextureUUID"]); |
1318 | newData.MediaURL = (String) row["MediaURL"]; | 1316 | newData.MediaURL = (String) row["MediaURL"]; |
1319 | newData.MusicURL = (String) row["MusicURL"]; | 1317 | newData.MusicURL = (String) row["MusicURL"]; |
1320 | newData.PassHours = Convert.ToSingle(row["PassHours"]); | 1318 | newData.PassHours = Convert.ToSingle(row["PassHours"]); |
@@ -1358,7 +1356,7 @@ namespace OpenSim.Data.MySQL | |||
1358 | private static ParcelManager.ParcelAccessEntry BuildLandAccessData(IDataReader row) | 1356 | private static ParcelManager.ParcelAccessEntry BuildLandAccessData(IDataReader row) |
1359 | { | 1357 | { |
1360 | ParcelManager.ParcelAccessEntry entry = new ParcelManager.ParcelAccessEntry(); | 1358 | ParcelManager.ParcelAccessEntry entry = new ParcelManager.ParcelAccessEntry(); |
1361 | entry.AgentID = new UUID((string) row["AccessUUID"]); | 1359 | entry.AgentID = DBGuid.FromDB(row["AccessUUID"]); |
1362 | entry.Flags = (AccessList) Convert.ToInt32(row["Flags"]); | 1360 | entry.Flags = (AccessList) Convert.ToInt32(row["Flags"]); |
1363 | entry.Time = new DateTime(); | 1361 | entry.Time = new DateTime(); |
1364 | return entry; | 1362 | return entry; |
diff --git a/OpenSim/Data/MySQL/MySQLMigrations.cs b/OpenSim/Data/MySQL/MySQLMigrations.cs new file mode 100644 index 0000000..81a0e83 --- /dev/null +++ b/OpenSim/Data/MySQL/MySQLMigrations.cs | |||
@@ -0,0 +1,83 @@ | |||
1 | /* | ||
2 | * Copyright (c) Contributors, http://opensimulator.org/ | ||
3 | * See CONTRIBUTORS.TXT for a full list of copyright holders. | ||
4 | * | ||
5 | * Redistribution and use in source and binary forms, with or without | ||
6 | * modification, are permitted provided that the following conditions are met: | ||
7 | * * Redistributions of source code must retain the above copyright | ||
8 | * notice, this list of conditions and the following disclaimer. | ||
9 | * * Redistributions in binary form must reproduce the above copyright | ||
10 | * notice, this list of conditions and the following disclaimer in the | ||
11 | * documentation and/or other materials provided with the distribution. | ||
12 | * * Neither the name of the OpenSimulator Project nor the | ||
13 | * names of its contributors may be used to endorse or promote products | ||
14 | * derived from this software without specific prior written permission. | ||
15 | * | ||
16 | * THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY | ||
17 | * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED | ||
18 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE | ||
19 | * DISCLAIMED. IN NO EVENT SHALL THE CONTRIBUTORS BE LIABLE FOR ANY | ||
20 | * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES | ||
21 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; | ||
22 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND | ||
23 | * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | ||
24 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS | ||
25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | ||
26 | */ | ||
27 | |||
28 | using System; | ||
29 | using System.Collections.Generic; | ||
30 | using System.Data; | ||
31 | using System.Data.Common; | ||
32 | using System.IO; | ||
33 | using System.Reflection; | ||
34 | using System.Text.RegularExpressions; | ||
35 | using log4net; | ||
36 | using MySql.Data.MySqlClient; | ||
37 | |||
38 | namespace OpenSim.Data.MySQL | ||
39 | { | ||
40 | /// <summary>This is a MySQL-customized migration processor. The only difference is in how | ||
41 | /// it executes SQL scripts (using MySqlScript instead of MyCommand) | ||
42 | /// | ||
43 | /// </summary> | ||
44 | public class MySqlMigration : Migration | ||
45 | { | ||
46 | public MySqlMigration() | ||
47 | : base() | ||
48 | { | ||
49 | } | ||
50 | |||
51 | public MySqlMigration(DbConnection conn, Assembly assem, string subtype, string type) : | ||
52 | base(conn, assem, subtype, type) | ||
53 | { | ||
54 | } | ||
55 | |||
56 | public MySqlMigration(DbConnection conn, Assembly assem, string type) : | ||
57 | base(conn, assem, type) | ||
58 | { | ||
59 | } | ||
60 | |||
61 | protected override void ExecuteScript(DbConnection conn, string[] script) | ||
62 | { | ||
63 | if (!(conn is MySqlConnection)) | ||
64 | { | ||
65 | base.ExecuteScript(conn, script); | ||
66 | return; | ||
67 | } | ||
68 | |||
69 | MySqlScript scr = new MySqlScript((MySqlConnection)conn); | ||
70 | { | ||
71 | foreach (string sql in script) | ||
72 | { | ||
73 | scr.Query = sql; | ||
74 | scr.Error += delegate(object sender, MySqlScriptErrorEventArgs args) | ||
75 | { | ||
76 | throw new Exception(sql); | ||
77 | }; | ||
78 | scr.Execute(); | ||
79 | } | ||
80 | } | ||
81 | } | ||
82 | } | ||
83 | } | ||
diff --git a/OpenSim/Data/MySQL/MySQLRegionData.cs b/OpenSim/Data/MySQL/MySQLRegionData.cs index aa9a104..c7bddac 100644 --- a/OpenSim/Data/MySQL/MySQLRegionData.cs +++ b/OpenSim/Data/MySQL/MySQLRegionData.cs | |||
@@ -31,6 +31,7 @@ using System.Collections.Generic; | |||
31 | using System.Data; | 31 | using System.Data; |
32 | using OpenMetaverse; | 32 | using OpenMetaverse; |
33 | using OpenSim.Framework; | 33 | using OpenSim.Framework; |
34 | using OpenSim.Data; | ||
34 | using MySql.Data.MySqlClient; | 35 | using MySql.Data.MySqlClient; |
35 | 36 | ||
36 | namespace OpenSim.Data.MySQL | 37 | namespace OpenSim.Data.MySQL |
@@ -143,12 +144,9 @@ namespace OpenSim.Data.MySQL | |||
143 | RegionData ret = new RegionData(); | 144 | RegionData ret = new RegionData(); |
144 | ret.Data = new Dictionary<string, object>(); | 145 | ret.Data = new Dictionary<string, object>(); |
145 | 146 | ||
146 | UUID regionID; | 147 | ret.RegionID = DBGuid.FromDB(result["uuid"]); |
147 | UUID.TryParse(result["uuid"].ToString(), out regionID); | 148 | ret.ScopeID = DBGuid.FromDB(result["ScopeID"]); |
148 | ret.RegionID = regionID; | 149 | |
149 | UUID scope; | ||
150 | UUID.TryParse(result["ScopeID"].ToString(), out scope); | ||
151 | ret.ScopeID = scope; | ||
152 | ret.RegionName = result["regionName"].ToString(); | 150 | ret.RegionName = result["regionName"].ToString(); |
153 | ret.posX = Convert.ToInt32(result["locX"]); | 151 | ret.posX = Convert.ToInt32(result["locX"]); |
154 | ret.posY = Convert.ToInt32(result["locY"]); | 152 | ret.posY = Convert.ToInt32(result["locY"]); |
diff --git a/OpenSim/Data/MySQL/Resources/001_AssetStore.sql b/OpenSim/Data/MySQL/Resources/001_AssetStore.sql deleted file mode 100644 index 6a9a127..0000000 --- a/OpenSim/Data/MySQL/Resources/001_AssetStore.sql +++ /dev/null | |||
@@ -1,15 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | CREATE TABLE `assets` ( | ||
4 | `id` binary(16) NOT NULL, | ||
5 | `name` varchar(64) NOT NULL, | ||
6 | `description` varchar(64) NOT NULL, | ||
7 | `assetType` tinyint(4) NOT NULL, | ||
8 | `invType` tinyint(4) NOT NULL, | ||
9 | `local` tinyint(1) NOT NULL, | ||
10 | `temporary` tinyint(1) NOT NULL, | ||
11 | `data` longblob NOT NULL, | ||
12 | PRIMARY KEY (`id`) | ||
13 | ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Rev. 1'; | ||
14 | |||
15 | COMMIT; \ No newline at end of file | ||
diff --git a/OpenSim/Data/MySQL/Resources/001_Avatar.sql b/OpenSim/Data/MySQL/Resources/001_Avatar.sql deleted file mode 100644 index 27a3072..0000000 --- a/OpenSim/Data/MySQL/Resources/001_Avatar.sql +++ /dev/null | |||
@@ -1,5 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | CREATE TABLE Avatars (PrincipalID CHAR(36) NOT NULL, Name VARCHAR(32) NOT NULL, Value VARCHAR(255) NOT NULL DEFAULT '', PRIMARY KEY(PrincipalID, Name), KEY(PrincipalID)); | ||
4 | |||
5 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/001_Friends.sql b/OpenSim/Data/MySQL/Resources/001_Friends.sql deleted file mode 100644 index e158a2c..0000000 --- a/OpenSim/Data/MySQL/Resources/001_Friends.sql +++ /dev/null | |||
@@ -1,9 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | CREATE TABLE `Friends` ( | ||
4 | `PrincipalID` CHAR(36) NOT NULL, | ||
5 | `FriendID` VARCHAR(255) NOT NULL, | ||
6 | `Flags` CHAR(16) NOT NULL DEFAULT '0' | ||
7 | ) ENGINE=InnoDB; | ||
8 | |||
9 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/001_FriendsStore.sql b/OpenSim/Data/MySQL/Resources/001_FriendsStore.sql deleted file mode 100644 index da2c59c..0000000 --- a/OpenSim/Data/MySQL/Resources/001_FriendsStore.sql +++ /dev/null | |||
@@ -1,5 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | CREATE TABLE `Friends` (`PrincipalID` CHAR(36) NOT NULL, `Friend` VARCHAR(255) NOT NULL, `Flags` VARCHAR(16) NOT NULL DEFAULT 0, `Offered` VARCHAR(32) NOT NULL DEFAULT 0, PRIMARY KEY(`PrincipalID`, `Friend`), KEY(`PrincipalID`)); | ||
4 | |||
5 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/001_InventoryStore.sql b/OpenSim/Data/MySQL/Resources/001_InventoryStore.sql deleted file mode 100644 index 40dc91c..0000000 --- a/OpenSim/Data/MySQL/Resources/001_InventoryStore.sql +++ /dev/null | |||
@@ -1,40 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | CREATE TABLE `inventoryfolders` ( | ||
4 | `folderID` varchar(36) NOT NULL default '', | ||
5 | `agentID` varchar(36) default NULL, | ||
6 | `parentFolderID` varchar(36) default NULL, | ||
7 | `folderName` varchar(64) default NULL, | ||
8 | `type` smallint NOT NULL default 0, | ||
9 | `version` int NOT NULL default 0, | ||
10 | PRIMARY KEY (`folderID`), | ||
11 | KEY `owner` (`agentID`), | ||
12 | KEY `parent` (`parentFolderID`) | ||
13 | ) ENGINE=InnoDB DEFAULT CHARSET=utf8; | ||
14 | |||
15 | CREATE TABLE `inventoryitems` ( | ||
16 | `inventoryID` varchar(36) NOT NULL default '', | ||
17 | `assetID` varchar(36) default NULL, | ||
18 | `assetType` int(11) default NULL, | ||
19 | `parentFolderID` varchar(36) default NULL, | ||
20 | `avatarID` varchar(36) default NULL, | ||
21 | `inventoryName` varchar(64) default NULL, | ||
22 | `inventoryDescription` varchar(128) default NULL, | ||
23 | `inventoryNextPermissions` int(10) unsigned default NULL, | ||
24 | `inventoryCurrentPermissions` int(10) unsigned default NULL, | ||
25 | `invType` int(11) default NULL, | ||
26 | `creatorID` varchar(36) default NULL, | ||
27 | `inventoryBasePermissions` int(10) unsigned NOT NULL default 0, | ||
28 | `inventoryEveryOnePermissions` int(10) unsigned NOT NULL default 0, | ||
29 | `salePrice` int(11) NOT NULL default 0, | ||
30 | `saleType` tinyint(4) NOT NULL default 0, | ||
31 | `creationDate` int(11) NOT NULL default 0, | ||
32 | `groupID` varchar(36) NOT NULL default '00000000-0000-0000-0000-000000000000', | ||
33 | `groupOwned` tinyint(4) NOT NULL default 0, | ||
34 | `flags` int(11) unsigned NOT NULL default 0, | ||
35 | PRIMARY KEY (`inventoryID`), | ||
36 | KEY `owner` (`avatarID`), | ||
37 | KEY `folder` (`parentFolderID`) | ||
38 | ) ENGINE=InnoDB DEFAULT CHARSET=utf8; | ||
39 | |||
40 | COMMIT; \ No newline at end of file | ||
diff --git a/OpenSim/Data/MySQL/Resources/001_RegionStore.sql b/OpenSim/Data/MySQL/Resources/001_RegionStore.sql deleted file mode 100644 index 31164b3..0000000 --- a/OpenSim/Data/MySQL/Resources/001_RegionStore.sql +++ /dev/null | |||
@@ -1,154 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | CREATE TABLE `prims` ( | ||
4 | `UUID` varchar(255) NOT NULL, | ||
5 | `RegionUUID` varchar(255) default NULL, | ||
6 | `ParentID` int(11) default NULL, | ||
7 | `CreationDate` int(11) default NULL, | ||
8 | `Name` varchar(255) default NULL, | ||
9 | `SceneGroupID` varchar(255) default NULL, | ||
10 | `Text` varchar(255) default NULL, | ||
11 | `Description` varchar(255) default NULL, | ||
12 | `SitName` varchar(255) default NULL, | ||
13 | `TouchName` varchar(255) default NULL, | ||
14 | `ObjectFlags` int(11) default NULL, | ||
15 | `CreatorID` varchar(255) default NULL, | ||
16 | `OwnerID` varchar(255) default NULL, | ||
17 | `GroupID` varchar(255) default NULL, | ||
18 | `LastOwnerID` varchar(255) default NULL, | ||
19 | `OwnerMask` int(11) default NULL, | ||
20 | `NextOwnerMask` int(11) default NULL, | ||
21 | `GroupMask` int(11) default NULL, | ||
22 | `EveryoneMask` int(11) default NULL, | ||
23 | `BaseMask` int(11) default NULL, | ||
24 | `PositionX` float default NULL, | ||
25 | `PositionY` float default NULL, | ||
26 | `PositionZ` float default NULL, | ||
27 | `GroupPositionX` float default NULL, | ||
28 | `GroupPositionY` float default NULL, | ||
29 | `GroupPositionZ` float default NULL, | ||
30 | `VelocityX` float default NULL, | ||
31 | `VelocityY` float default NULL, | ||
32 | `VelocityZ` float default NULL, | ||
33 | `AngularVelocityX` float default NULL, | ||
34 | `AngularVelocityY` float default NULL, | ||
35 | `AngularVelocityZ` float default NULL, | ||
36 | `AccelerationX` float default NULL, | ||
37 | `AccelerationY` float default NULL, | ||
38 | `AccelerationZ` float default NULL, | ||
39 | `RotationX` float default NULL, | ||
40 | `RotationY` float default NULL, | ||
41 | `RotationZ` float default NULL, | ||
42 | `RotationW` float default NULL, | ||
43 | `SitTargetOffsetX` float default NULL, | ||
44 | `SitTargetOffsetY` float default NULL, | ||
45 | `SitTargetOffsetZ` float default NULL, | ||
46 | `SitTargetOrientW` float default NULL, | ||
47 | `SitTargetOrientX` float default NULL, | ||
48 | `SitTargetOrientY` float default NULL, | ||
49 | `SitTargetOrientZ` float default NULL, | ||
50 | PRIMARY KEY (`UUID`) | ||
51 | ) ENGINE=MyISAM DEFAULT CHARSET=latin1; | ||
52 | |||
53 | CREATE TABLE `primshapes` ( | ||
54 | `UUID` varchar(255) NOT NULL, | ||
55 | `Shape` int(11) default NULL, | ||
56 | `ScaleX` float default NULL, | ||
57 | `ScaleY` float default NULL, | ||
58 | `ScaleZ` float default NULL, | ||
59 | `PCode` int(11) default NULL, | ||
60 | `PathBegin` int(11) default NULL, | ||
61 | `PathEnd` int(11) default NULL, | ||
62 | `PathScaleX` int(11) default NULL, | ||
63 | `PathScaleY` int(11) default NULL, | ||
64 | `PathShearX` int(11) default NULL, | ||
65 | `PathShearY` int(11) default NULL, | ||
66 | `PathSkew` int(11) default NULL, | ||
67 | `PathCurve` int(11) default NULL, | ||
68 | `PathRadiusOffset` int(11) default NULL, | ||
69 | `PathRevolutions` int(11) default NULL, | ||
70 | `PathTaperX` int(11) default NULL, | ||
71 | `PathTaperY` int(11) default NULL, | ||
72 | `PathTwist` int(11) default NULL, | ||
73 | `PathTwistBegin` int(11) default NULL, | ||
74 | `ProfileBegin` int(11) default NULL, | ||
75 | `ProfileEnd` int(11) default NULL, | ||
76 | `ProfileCurve` int(11) default NULL, | ||
77 | `ProfileHollow` int(11) default NULL, | ||
78 | `State` int(11) default NULL, | ||
79 | `Texture` longblob, | ||
80 | `ExtraParams` longblob, | ||
81 | PRIMARY KEY (`UUID`) | ||
82 | ) ENGINE=MyISAM DEFAULT CHARSET=latin1; | ||
83 | |||
84 | CREATE TABLE `primitems` ( | ||
85 | `itemID` varchar(255) NOT NULL, | ||
86 | `primID` varchar(255) default NULL, | ||
87 | `assetID` varchar(255) default NULL, | ||
88 | `parentFolderID` varchar(255) default NULL, | ||
89 | `invType` int(11) default NULL, | ||
90 | `assetType` int(11) default NULL, | ||
91 | `name` varchar(255) default NULL, | ||
92 | `description` varchar(255) default NULL, | ||
93 | `creationDate` bigint(20) default NULL, | ||
94 | `creatorID` varchar(255) default NULL, | ||
95 | `ownerID` varchar(255) default NULL, | ||
96 | `lastOwnerID` varchar(255) default NULL, | ||
97 | `groupID` varchar(255) default NULL, | ||
98 | `nextPermissions` int(11) default NULL, | ||
99 | `currentPermissions` int(11) default NULL, | ||
100 | `basePermissions` int(11) default NULL, | ||
101 | `everyonePermissions` int(11) default NULL, | ||
102 | `groupPermissions` int(11) default NULL, | ||
103 | PRIMARY KEY (`itemID`) | ||
104 | ) ENGINE=MyISAM DEFAULT CHARSET=latin1; | ||
105 | |||
106 | CREATE TABLE `terrain` ( | ||
107 | `RegionUUID` varchar(255) default NULL, | ||
108 | `Revision` int(11) default NULL, | ||
109 | `Heightfield` longblob | ||
110 | ) ENGINE=MyISAM DEFAULT CHARSET=latin1; | ||
111 | |||
112 | CREATE TABLE `land` ( | ||
113 | `UUID` varchar(255) NOT NULL, | ||
114 | `RegionUUID` varchar(255) default NULL, | ||
115 | `LocalLandID` int(11) default NULL, | ||
116 | `Bitmap` longblob, | ||
117 | `Name` varchar(255) default NULL, | ||
118 | `Description` varchar(255) default NULL, | ||
119 | `OwnerUUID` varchar(255) default NULL, | ||
120 | `IsGroupOwned` int(11) default NULL, | ||
121 | `Area` int(11) default NULL, | ||
122 | `AuctionID` int(11) default NULL, | ||
123 | `Category` int(11) default NULL, | ||
124 | `ClaimDate` int(11) default NULL, | ||
125 | `ClaimPrice` int(11) default NULL, | ||
126 | `GroupUUID` varchar(255) default NULL, | ||
127 | `SalePrice` int(11) default NULL, | ||
128 | `LandStatus` int(11) default NULL, | ||
129 | `LandFlags` int(11) default NULL, | ||
130 | `LandingType` int(11) default NULL, | ||
131 | `MediaAutoScale` int(11) default NULL, | ||
132 | `MediaTextureUUID` varchar(255) default NULL, | ||
133 | `MediaURL` varchar(255) default NULL, | ||
134 | `MusicURL` varchar(255) default NULL, | ||
135 | `PassHours` float default NULL, | ||
136 | `PassPrice` int(11) default NULL, | ||
137 | `SnapshotUUID` varchar(255) default NULL, | ||
138 | `UserLocationX` float default NULL, | ||
139 | `UserLocationY` float default NULL, | ||
140 | `UserLocationZ` float default NULL, | ||
141 | `UserLookAtX` float default NULL, | ||
142 | `UserLookAtY` float default NULL, | ||
143 | `UserLookAtZ` float default NULL, | ||
144 | `AuthbuyerID` varchar(36) NOT NULL default '00000000-0000-0000-0000-000000000000', | ||
145 | PRIMARY KEY (`UUID`) | ||
146 | ) ENGINE=InnoDB DEFAULT CHARSET=utf8; | ||
147 | |||
148 | CREATE TABLE `landaccesslist` ( | ||
149 | `LandUUID` varchar(255) default NULL, | ||
150 | `AccessUUID` varchar(255) default NULL, | ||
151 | `Flags` int(11) default NULL | ||
152 | ) ENGINE=MyISAM DEFAULT CHARSET=latin1; | ||
153 | |||
154 | COMMIT; \ No newline at end of file | ||
diff --git a/OpenSim/Data/MySQL/Resources/001_UserAccount.sql b/OpenSim/Data/MySQL/Resources/001_UserAccount.sql deleted file mode 100644 index 07da571..0000000 --- a/OpenSim/Data/MySQL/Resources/001_UserAccount.sql +++ /dev/null | |||
@@ -1,13 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | CREATE TABLE `UserAccounts` ( | ||
4 | `PrincipalID` CHAR(36) NOT NULL, | ||
5 | `ScopeID` CHAR(36) NOT NULL, | ||
6 | `FirstName` VARCHAR(64) NOT NULL, | ||
7 | `LastName` VARCHAR(64) NOT NULL, | ||
8 | `Email` VARCHAR(64), | ||
9 | `ServiceURLs` TEXT, | ||
10 | `Created` INT(11) | ||
11 | ) ENGINE=InnoDB DEFAULT CHARSET=utf8; | ||
12 | |||
13 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/002_AssetStore.sql b/OpenSim/Data/MySQL/Resources/002_AssetStore.sql deleted file mode 100644 index a7d7fca..0000000 --- a/OpenSim/Data/MySQL/Resources/002_AssetStore.sql +++ /dev/null | |||
@@ -1,9 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE assets change id oldid binary(16); | ||
4 | ALTER TABLE assets add id varchar(36) not null default ''; | ||
5 | UPDATE assets set id = concat(substr(hex(oldid),1,8),"-",substr(hex(oldid),9,4),"-",substr(hex(oldid),13,4),"-",substr(hex(oldid),17,4),"-",substr(hex(oldid),21,12)); | ||
6 | ALTER TABLE assets drop oldid; | ||
7 | ALTER TABLE assets add constraint primary key(id); | ||
8 | |||
9 | COMMIT; \ No newline at end of file | ||
diff --git a/OpenSim/Data/MySQL/Resources/002_AuthStore.sql b/OpenSim/Data/MySQL/Resources/002_AuthStore.sql deleted file mode 100644 index dc7dfe0..0000000 --- a/OpenSim/Data/MySQL/Resources/002_AuthStore.sql +++ /dev/null | |||
@@ -1,5 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | INSERT INTO auth (UUID, passwordHash, passwordSalt, webLoginKey) SELECT `UUID` AS UUID, `passwordHash` AS passwordHash, `passwordSalt` AS passwordSalt, `webLoginKey` AS webLoginKey FROM users; | ||
4 | |||
5 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/002_Friends.sql b/OpenSim/Data/MySQL/Resources/002_Friends.sql deleted file mode 100644 index 5ff6438..0000000 --- a/OpenSim/Data/MySQL/Resources/002_Friends.sql +++ /dev/null | |||
@@ -1,5 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | INSERT INTO Friends (PrincipalID, FriendID, Flags) SELECT ownerID, friendID, friendPerms FROM userfriends; | ||
4 | |||
5 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/002_FriendsStore.sql b/OpenSim/Data/MySQL/Resources/002_FriendsStore.sql deleted file mode 100644 index a363867..0000000 --- a/OpenSim/Data/MySQL/Resources/002_FriendsStore.sql +++ /dev/null | |||
@@ -1,5 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | INSERT INTO `Friends` SELECT `ownerID`, `friendID`, `friendPerms`, 0 FROM `userfriends`; | ||
4 | |||
5 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/002_GridStore.sql b/OpenSim/Data/MySQL/Resources/002_GridStore.sql deleted file mode 100644 index 35b9be1..0000000 --- a/OpenSim/Data/MySQL/Resources/002_GridStore.sql +++ /dev/null | |||
@@ -1,5 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE regions add column access integer unsigned default 1; | ||
4 | |||
5 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/002_InventoryStore.sql b/OpenSim/Data/MySQL/Resources/002_InventoryStore.sql deleted file mode 100644 index c161a68..0000000 --- a/OpenSim/Data/MySQL/Resources/002_InventoryStore.sql +++ /dev/null | |||
@@ -1,31 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE inventoryfolders change folderID folderIDold varchar(36); | ||
4 | ALTER TABLE inventoryfolders change agentID agentIDold varchar(36); | ||
5 | ALTER TABLE inventoryfolders change parentFolderID parentFolderIDold varchar(36); | ||
6 | ALTER TABLE inventoryfolders add folderID char(36) not null default '00000000-0000-0000-0000-000000000000'; | ||
7 | ALTER TABLE inventoryfolders add agentID char(36) default NULL; | ||
8 | ALTER TABLE inventoryfolders add parentFolderID char(36) default NULL; | ||
9 | UPDATE inventoryfolders set folderID = folderIDold, agentID = agentIDold, parentFolderID = parentFolderIDold; | ||
10 | ALTER TABLE inventoryfolders drop folderIDold; | ||
11 | ALTER TABLE inventoryfolders drop agentIDold; | ||
12 | ALTER TABLE inventoryfolders drop parentFolderIDold; | ||
13 | ALTER TABLE inventoryfolders add constraint primary key(folderID); | ||
14 | ALTER TABLE inventoryfolders add index inventoryfolders_agentid(agentID); | ||
15 | ALTER TABLE inventoryfolders add index inventoryfolders_parentFolderid(parentFolderID); | ||
16 | |||
17 | ALTER TABLE inventoryitems change inventoryID inventoryIDold varchar(36); | ||
18 | ALTER TABLE inventoryitems change avatarID avatarIDold varchar(36); | ||
19 | ALTER TABLE inventoryitems change parentFolderID parentFolderIDold varchar(36); | ||
20 | ALTER TABLE inventoryitems add inventoryID char(36) not null default '00000000-0000-0000-0000-000000000000'; | ||
21 | ALTER TABLE inventoryitems add avatarID char(36) default NULL; | ||
22 | ALTER TABLE inventoryitems add parentFolderID char(36) default NULL; | ||
23 | UPDATE inventoryitems set inventoryID = inventoryIDold, avatarID = avatarIDold, parentFolderID = parentFolderIDold; | ||
24 | ALTER TABLE inventoryitems drop inventoryIDold; | ||
25 | ALTER TABLE inventoryitems drop avatarIDold; | ||
26 | ALTER TABLE inventoryitems drop parentFolderIDold; | ||
27 | ALTER TABLE inventoryitems add constraint primary key(inventoryID); | ||
28 | ALTER TABLE inventoryitems add index inventoryitems_avatarid(avatarID); | ||
29 | ALTER TABLE inventoryitems add index inventoryitems_parentFolderid(parentFolderID); | ||
30 | |||
31 | COMMIT; \ No newline at end of file | ||
diff --git a/OpenSim/Data/MySQL/Resources/002_RegionStore.sql b/OpenSim/Data/MySQL/Resources/002_RegionStore.sql deleted file mode 100644 index 45bf959..0000000 --- a/OpenSim/Data/MySQL/Resources/002_RegionStore.sql +++ /dev/null | |||
@@ -1,6 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | CREATE index prims_regionuuid on prims(RegionUUID); | ||
4 | CREATE index primitems_primid on primitems(primID); | ||
5 | |||
6 | COMMIT; \ No newline at end of file | ||
diff --git a/OpenSim/Data/MySQL/Resources/002_UserAccount.sql b/OpenSim/Data/MySQL/Resources/002_UserAccount.sql deleted file mode 100644 index ad2ddda..0000000 --- a/OpenSim/Data/MySQL/Resources/002_UserAccount.sql +++ /dev/null | |||
@@ -1,5 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | INSERT INTO UserAccounts (PrincipalID, ScopeID, FirstName, LastName, Email, ServiceURLs, Created) SELECT `UUID` AS PrincipalID, '00000000-0000-0000-0000-000000000000' AS ScopeID, username AS FirstName, lastname AS LastName, email as Email, CONCAT('AssetServerURI=', userAssetURI, ' InventoryServerURI=', userInventoryURI, ' GatewayURI= HomeURI=') AS ServiceURLs, created as Created FROM users; | ||
4 | |||
5 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/002_UserStore.sql b/OpenSim/Data/MySQL/Resources/002_UserStore.sql deleted file mode 100644 index 393cea0..0000000 --- a/OpenSim/Data/MySQL/Resources/002_UserStore.sql +++ /dev/null | |||
@@ -1,5 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE users add homeRegionID char(36) NOT NULL default '00000000-0000-0000-0000-000000000000'; | ||
4 | |||
5 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/003_AssetStore.sql b/OpenSim/Data/MySQL/Resources/003_AssetStore.sql deleted file mode 100644 index d489278..0000000 --- a/OpenSim/Data/MySQL/Resources/003_AssetStore.sql +++ /dev/null | |||
@@ -1,9 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE assets change id oldid varchar(36); | ||
4 | ALTER TABLE assets add id char(36) not null default '00000000-0000-0000-0000-000000000000'; | ||
5 | UPDATE assets set id = oldid; | ||
6 | ALTER TABLE assets drop oldid; | ||
7 | ALTER TABLE assets add constraint primary key(id); | ||
8 | |||
9 | COMMIT; \ No newline at end of file | ||
diff --git a/OpenSim/Data/MySQL/Resources/003_AuthStore.sql b/OpenSim/Data/MySQL/Resources/003_AuthStore.sql deleted file mode 100644 index af9ffe6..0000000 --- a/OpenSim/Data/MySQL/Resources/003_AuthStore.sql +++ /dev/null | |||
@@ -1,5 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE `auth` ADD COLUMN `accountType` VARCHAR(32) NOT NULL DEFAULT 'UserAccount'; | ||
4 | |||
5 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/003_GridStore.sql b/OpenSim/Data/MySQL/Resources/003_GridStore.sql deleted file mode 100644 index bc3fe7d..0000000 --- a/OpenSim/Data/MySQL/Resources/003_GridStore.sql +++ /dev/null | |||
@@ -1,7 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE regions add column ScopeID char(36) not null default '00000000-0000-0000-0000-000000000000'; | ||
4 | |||
5 | create index ScopeID on regions(ScopeID); | ||
6 | |||
7 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/003_InventoryStore.sql b/OpenSim/Data/MySQL/Resources/003_InventoryStore.sql deleted file mode 100644 index 4c6da91..0000000 --- a/OpenSim/Data/MySQL/Resources/003_InventoryStore.sql +++ /dev/null | |||
@@ -1,5 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | alter table inventoryitems add column inventoryGroupPermissions integer unsigned not null default 0; | ||
4 | |||
5 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/003_RegionStore.sql b/OpenSim/Data/MySQL/Resources/003_RegionStore.sql deleted file mode 100644 index cb0a614..0000000 --- a/OpenSim/Data/MySQL/Resources/003_RegionStore.sql +++ /dev/null | |||
@@ -1,5 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | CREATE TABLE regionban (regionUUID VARCHAR(36) NOT NULL, bannedUUID VARCHAR(36) NOT NULL, bannedIp VARCHAR(16) NOT NULL, bannedIpHostMask VARCHAR(16) NOT NULL) ENGINE=INNODB DEFAULT CHARSET=utf8 COMMENT='Rev. 1'; | ||
4 | |||
5 | COMMIT; \ No newline at end of file | ||
diff --git a/OpenSim/Data/MySQL/Resources/003_UserAccount.sql b/OpenSim/Data/MySQL/Resources/003_UserAccount.sql deleted file mode 100644 index e42d93b..0000000 --- a/OpenSim/Data/MySQL/Resources/003_UserAccount.sql +++ /dev/null | |||
@@ -1,9 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | CREATE UNIQUE INDEX PrincipalID ON UserAccounts(PrincipalID); | ||
4 | CREATE INDEX Email ON UserAccounts(Email); | ||
5 | CREATE INDEX FirstName ON UserAccounts(FirstName); | ||
6 | CREATE INDEX LastName ON UserAccounts(LastName); | ||
7 | CREATE INDEX Name ON UserAccounts(FirstName,LastName); | ||
8 | |||
9 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/003_UserStore.sql b/OpenSim/Data/MySQL/Resources/003_UserStore.sql deleted file mode 100644 index 6f890ee..0000000 --- a/OpenSim/Data/MySQL/Resources/003_UserStore.sql +++ /dev/null | |||
@@ -1,6 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE users add userFlags integer NOT NULL default 0; | ||
4 | ALTER TABLE users add godLevel integer NOT NULL default 0; | ||
5 | |||
6 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/004_AssetStore.sql b/OpenSim/Data/MySQL/Resources/004_AssetStore.sql deleted file mode 100644 index ae1951d..0000000 --- a/OpenSim/Data/MySQL/Resources/004_AssetStore.sql +++ /dev/null | |||
@@ -1,5 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE assets drop InvType; | ||
4 | |||
5 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/004_GridStore.sql b/OpenSim/Data/MySQL/Resources/004_GridStore.sql deleted file mode 100644 index 2238a88..0000000 --- a/OpenSim/Data/MySQL/Resources/004_GridStore.sql +++ /dev/null | |||
@@ -1,6 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE regions add column sizeX integer not null default 0; | ||
4 | ALTER TABLE regions add column sizeY integer not null default 0; | ||
5 | |||
6 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/004_InventoryStore.sql b/OpenSim/Data/MySQL/Resources/004_InventoryStore.sql deleted file mode 100644 index c45f773..0000000 --- a/OpenSim/Data/MySQL/Resources/004_InventoryStore.sql +++ /dev/null | |||
@@ -1,7 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | update inventoryitems set creatorID = '00000000-0000-0000-0000-000000000000' where creatorID is NULL; | ||
4 | update inventoryitems set creatorID = '00000000-0000-0000-0000-000000000000' where creatorID = ''; | ||
5 | alter table inventoryitems modify column creatorID varchar(36) not NULL default '00000000-0000-0000-0000-000000000000'; | ||
6 | |||
7 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/004_RegionStore.sql b/OpenSim/Data/MySQL/Resources/004_RegionStore.sql deleted file mode 100644 index 4db2f75..0000000 --- a/OpenSim/Data/MySQL/Resources/004_RegionStore.sql +++ /dev/null | |||
@@ -1,5 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE primitems add flags integer not null default 0; | ||
4 | |||
5 | COMMIT; \ No newline at end of file | ||
diff --git a/OpenSim/Data/MySQL/Resources/004_UserAccount.sql b/OpenSim/Data/MySQL/Resources/004_UserAccount.sql deleted file mode 100644 index 8abcd53..0000000 --- a/OpenSim/Data/MySQL/Resources/004_UserAccount.sql +++ /dev/null | |||
@@ -1,8 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE UserAccounts ADD COLUMN UserLevel integer NOT NULL DEFAULT 0; | ||
4 | ALTER TABLE UserAccounts ADD COLUMN UserFlags integer NOT NULL DEFAULT 0; | ||
5 | ALTER TABLE UserAccounts ADD COLUMN UserTitle varchar(64) NOT NULL DEFAULT ''; | ||
6 | |||
7 | COMMIT; | ||
8 | |||
diff --git a/OpenSim/Data/MySQL/Resources/004_UserStore.sql b/OpenSim/Data/MySQL/Resources/004_UserStore.sql deleted file mode 100644 index 03142af..0000000 --- a/OpenSim/Data/MySQL/Resources/004_UserStore.sql +++ /dev/null | |||
@@ -1,6 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE users add customType varchar(32) not null default ''; | ||
4 | ALTER TABLE users add partner char(36) not null default '00000000-0000-0000-0000-000000000000'; | ||
5 | |||
6 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/005_AssetStore.sql b/OpenSim/Data/MySQL/Resources/005_AssetStore.sql deleted file mode 100644 index bfeb652..0000000 --- a/OpenSim/Data/MySQL/Resources/005_AssetStore.sql +++ /dev/null | |||
@@ -1,6 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE assets add create_time integer default 0; | ||
4 | ALTER TABLE assets add access_time integer default 0; | ||
5 | |||
6 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/005_GridStore.sql b/OpenSim/Data/MySQL/Resources/005_GridStore.sql deleted file mode 100644 index 835ba89..0000000 --- a/OpenSim/Data/MySQL/Resources/005_GridStore.sql +++ /dev/null | |||
@@ -1,6 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE `regions` ADD COLUMN `flags` integer NOT NULL DEFAULT 0; | ||
4 | CREATE INDEX flags ON regions(flags); | ||
5 | |||
6 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/005_RegionStore.sql b/OpenSim/Data/MySQL/Resources/005_RegionStore.sql deleted file mode 100644 index c4a9527..0000000 --- a/OpenSim/Data/MySQL/Resources/005_RegionStore.sql +++ /dev/null | |||
@@ -1,40 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | create table regionsettings ( | ||
4 | regionUUID char(36) not null, | ||
5 | block_terraform integer not null, | ||
6 | block_fly integer not null, | ||
7 | allow_damage integer not null, | ||
8 | restrict_pushing integer not null, | ||
9 | allow_land_resell integer not null, | ||
10 | allow_land_join_divide integer not null, | ||
11 | block_show_in_search integer not null, | ||
12 | agent_limit integer not null, | ||
13 | object_bonus float not null, | ||
14 | maturity integer not null, | ||
15 | disable_scripts integer not null, | ||
16 | disable_collisions integer not null, | ||
17 | disable_physics integer not null, | ||
18 | terrain_texture_1 char(36) not null, | ||
19 | terrain_texture_2 char(36) not null, | ||
20 | terrain_texture_3 char(36) not null, | ||
21 | terrain_texture_4 char(36) not null, | ||
22 | elevation_1_nw float not null, | ||
23 | elevation_2_nw float not null, | ||
24 | elevation_1_ne float not null, | ||
25 | elevation_2_ne float not null, | ||
26 | elevation_1_se float not null, | ||
27 | elevation_2_se float not null, | ||
28 | elevation_1_sw float not null, | ||
29 | elevation_2_sw float not null, | ||
30 | water_height float not null, | ||
31 | terrain_raise_limit float not null, | ||
32 | terrain_lower_limit float not null, | ||
33 | use_estate_sun integer not null, | ||
34 | fixed_sun integer not null, | ||
35 | sun_position float not null, | ||
36 | covenant char(36), | ||
37 | primary key(regionUUID) | ||
38 | ); | ||
39 | |||
40 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/005_UserStore.sql b/OpenSim/Data/MySQL/Resources/005_UserStore.sql deleted file mode 100644 index 55896bc..0000000 --- a/OpenSim/Data/MySQL/Resources/005_UserStore.sql +++ /dev/null | |||
@@ -1,5 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | CREATE TABLE `avatarattachments` (`UUID` char(36) NOT NULL, `attachpoint` int(11) NOT NULL, `item` char(36) NOT NULL, `asset` char(36) NOT NULL) ENGINE=InnoDB; | ||
4 | |||
5 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/006_AssetStore.sql b/OpenSim/Data/MySQL/Resources/006_AssetStore.sql deleted file mode 100644 index 3104353..0000000 --- a/OpenSim/Data/MySQL/Resources/006_AssetStore.sql +++ /dev/null | |||
@@ -1 +0,0 @@ | |||
1 | DELETE FROM assets WHERE id = 'dc4b9f0b-d008-45c6-96a4-01dd947ac621' | ||
diff --git a/OpenSim/Data/MySQL/Resources/006_GridStore.sql b/OpenSim/Data/MySQL/Resources/006_GridStore.sql deleted file mode 100644 index 91322d6..0000000 --- a/OpenSim/Data/MySQL/Resources/006_GridStore.sql +++ /dev/null | |||
@@ -1,5 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE `regions` ADD COLUMN `last_seen` integer NOT NULL DEFAULT 0; | ||
4 | |||
5 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/006_RegionStore.sql b/OpenSim/Data/MySQL/Resources/006_RegionStore.sql deleted file mode 100644 index c1ba5b8..0000000 --- a/OpenSim/Data/MySQL/Resources/006_RegionStore.sql +++ /dev/null | |||
@@ -1,12 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | alter table landaccesslist ENGINE = InnoDB; | ||
4 | alter table migrations ENGINE = InnoDB; | ||
5 | alter table primitems ENGINE = InnoDB; | ||
6 | alter table prims ENGINE = InnoDB; | ||
7 | alter table primshapes ENGINE = InnoDB; | ||
8 | alter table regionsettings ENGINE = InnoDB; | ||
9 | alter table terrain ENGINE = InnoDB; | ||
10 | |||
11 | COMMIT; | ||
12 | |||
diff --git a/OpenSim/Data/MySQL/Resources/006_UserStore.sql b/OpenSim/Data/MySQL/Resources/006_UserStore.sql deleted file mode 100644 index 10b321e..0000000 --- a/OpenSim/Data/MySQL/Resources/006_UserStore.sql +++ /dev/null | |||
@@ -1,5 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE agents add currentLookAt varchar(36) not null default ''; | ||
4 | |||
5 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/007_AssetStore.sql b/OpenSim/Data/MySQL/Resources/007_AssetStore.sql deleted file mode 100644 index f06121a..0000000 --- a/OpenSim/Data/MySQL/Resources/007_AssetStore.sql +++ /dev/null | |||
@@ -1,5 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE assets ADD COLUMN asset_flags INTEGER NOT NULL DEFAULT 0; | ||
4 | |||
5 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/007_GridStore.sql b/OpenSim/Data/MySQL/Resources/007_GridStore.sql deleted file mode 100644 index dbec584..0000000 --- a/OpenSim/Data/MySQL/Resources/007_GridStore.sql +++ /dev/null | |||
@@ -1,7 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE `regions` ADD COLUMN `PrincipalID` char(36) NOT NULL DEFAULT '00000000-0000-0000-0000-000000000000'; | ||
4 | ALTER TABLE `regions` ADD COLUMN `Token` varchar(255) NOT NULL; | ||
5 | |||
6 | COMMIT; | ||
7 | |||
diff --git a/OpenSim/Data/MySQL/Resources/007_RegionStore.sql b/OpenSim/Data/MySQL/Resources/007_RegionStore.sql deleted file mode 100644 index 404d248..0000000 --- a/OpenSim/Data/MySQL/Resources/007_RegionStore.sql +++ /dev/null | |||
@@ -1,25 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE prims change UUID UUIDold varchar(255); | ||
4 | ALTER TABLE prims change RegionUUID RegionUUIDold varchar(255); | ||
5 | ALTER TABLE prims change CreatorID CreatorIDold varchar(255); | ||
6 | ALTER TABLE prims change OwnerID OwnerIDold varchar(255); | ||
7 | ALTER TABLE prims change GroupID GroupIDold varchar(255); | ||
8 | ALTER TABLE prims change LastOwnerID LastOwnerIDold varchar(255); | ||
9 | ALTER TABLE prims add UUID char(36); | ||
10 | ALTER TABLE prims add RegionUUID char(36); | ||
11 | ALTER TABLE prims add CreatorID char(36); | ||
12 | ALTER TABLE prims add OwnerID char(36); | ||
13 | ALTER TABLE prims add GroupID char(36); | ||
14 | ALTER TABLE prims add LastOwnerID char(36); | ||
15 | UPDATE prims set UUID = UUIDold, RegionUUID = RegionUUIDold, CreatorID = CreatorIDold, OwnerID = OwnerIDold, GroupID = GroupIDold, LastOwnerID = LastOwnerIDold; | ||
16 | ALTER TABLE prims drop UUIDold; | ||
17 | ALTER TABLE prims drop RegionUUIDold; | ||
18 | ALTER TABLE prims drop CreatorIDold; | ||
19 | ALTER TABLE prims drop OwnerIDold; | ||
20 | ALTER TABLE prims drop GroupIDold; | ||
21 | ALTER TABLE prims drop LastOwnerIDold; | ||
22 | ALTER TABLE prims add constraint primary key(UUID); | ||
23 | ALTER TABLE prims add index prims_regionuuid(RegionUUID); | ||
24 | |||
25 | COMMIT; \ No newline at end of file | ||
diff --git a/OpenSim/Data/MySQL/Resources/007_UserStore.sql b/OpenSim/Data/MySQL/Resources/007_UserStore.sql deleted file mode 100644 index 3ab5261..0000000 --- a/OpenSim/Data/MySQL/Resources/007_UserStore.sql +++ /dev/null | |||
@@ -1,5 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE users add email varchar(250); | ||
4 | |||
5 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/008_RegionStore.sql b/OpenSim/Data/MySQL/Resources/008_RegionStore.sql deleted file mode 100644 index 7bc61c0..0000000 --- a/OpenSim/Data/MySQL/Resources/008_RegionStore.sql +++ /dev/null | |||
@@ -1,9 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE primshapes change UUID UUIDold varchar(255); | ||
4 | ALTER TABLE primshapes add UUID char(36); | ||
5 | UPDATE primshapes set UUID = UUIDold; | ||
6 | ALTER TABLE primshapes drop UUIDold; | ||
7 | ALTER TABLE primshapes add constraint primary key(UUID); | ||
8 | |||
9 | COMMIT; \ No newline at end of file | ||
diff --git a/OpenSim/Data/MySQL/Resources/008_UserStore.sql b/OpenSim/Data/MySQL/Resources/008_UserStore.sql deleted file mode 100644 index 4500bd5..0000000 --- a/OpenSim/Data/MySQL/Resources/008_UserStore.sql +++ /dev/null | |||
@@ -1,5 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE users add scopeID char(36) not null default '00000000-0000-0000-0000-000000000000'; | ||
4 | |||
5 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/009_RegionStore.sql b/OpenSim/Data/MySQL/Resources/009_RegionStore.sql deleted file mode 100644 index 284732a..0000000 --- a/OpenSim/Data/MySQL/Resources/009_RegionStore.sql +++ /dev/null | |||
@@ -1,31 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE primitems change itemID itemIDold varchar(255); | ||
4 | ALTER TABLE primitems change primID primIDold varchar(255); | ||
5 | ALTER TABLE primitems change assetID assetIDold varchar(255); | ||
6 | ALTER TABLE primitems change parentFolderID parentFolderIDold varchar(255); | ||
7 | ALTER TABLE primitems change creatorID creatorIDold varchar(255); | ||
8 | ALTER TABLE primitems change ownerID ownerIDold varchar(255); | ||
9 | ALTER TABLE primitems change groupID groupIDold varchar(255); | ||
10 | ALTER TABLE primitems change lastOwnerID lastOwnerIDold varchar(255); | ||
11 | ALTER TABLE primitems add itemID char(36); | ||
12 | ALTER TABLE primitems add primID char(36); | ||
13 | ALTER TABLE primitems add assetID char(36); | ||
14 | ALTER TABLE primitems add parentFolderID char(36); | ||
15 | ALTER TABLE primitems add creatorID char(36); | ||
16 | ALTER TABLE primitems add ownerID char(36); | ||
17 | ALTER TABLE primitems add groupID char(36); | ||
18 | ALTER TABLE primitems add lastOwnerID char(36); | ||
19 | UPDATE primitems set itemID = itemIDold, primID = primIDold, assetID = assetIDold, parentFolderID = parentFolderIDold, creatorID = creatorIDold, ownerID = ownerIDold, groupID = groupIDold, lastOwnerID = lastOwnerIDold; | ||
20 | ALTER TABLE primitems drop itemIDold; | ||
21 | ALTER TABLE primitems drop primIDold; | ||
22 | ALTER TABLE primitems drop assetIDold; | ||
23 | ALTER TABLE primitems drop parentFolderIDold; | ||
24 | ALTER TABLE primitems drop creatorIDold; | ||
25 | ALTER TABLE primitems drop ownerIDold; | ||
26 | ALTER TABLE primitems drop groupIDold; | ||
27 | ALTER TABLE primitems drop lastOwnerIDold; | ||
28 | ALTER TABLE primitems add constraint primary key(itemID); | ||
29 | ALTER TABLE primitems add index primitems_primid(primID); | ||
30 | |||
31 | COMMIT; \ No newline at end of file | ||
diff --git a/OpenSim/Data/MySQL/Resources/010_RegionStore.sql b/OpenSim/Data/MySQL/Resources/010_RegionStore.sql deleted file mode 100644 index 031a746..0000000 --- a/OpenSim/Data/MySQL/Resources/010_RegionStore.sql +++ /dev/null | |||
@@ -1,9 +0,0 @@ | |||
1 | # 1 "010_RegionStore.sql" | ||
2 | # 1 "<built-in>" | ||
3 | # 1 "<command line>" | ||
4 | # 1 "010_RegionStore.sql" | ||
5 | BEGIN; | ||
6 | |||
7 | DELETE FROM regionsettings; | ||
8 | |||
9 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/011_RegionStore.sql b/OpenSim/Data/MySQL/Resources/011_RegionStore.sql deleted file mode 100644 index ab01969..0000000 --- a/OpenSim/Data/MySQL/Resources/011_RegionStore.sql +++ /dev/null | |||
@@ -1,9 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE prims change SceneGroupID SceneGroupIDold varchar(255); | ||
4 | ALTER TABLE prims add SceneGroupID char(36); | ||
5 | UPDATE prims set SceneGroupID = SceneGroupIDold; | ||
6 | ALTER TABLE prims drop SceneGroupIDold; | ||
7 | ALTER TABLE prims add index prims_scenegroupid(SceneGroupID); | ||
8 | |||
9 | COMMIT; \ No newline at end of file | ||
diff --git a/OpenSim/Data/MySQL/Resources/012_RegionStore.sql b/OpenSim/Data/MySQL/Resources/012_RegionStore.sql deleted file mode 100644 index 95c2757..0000000 --- a/OpenSim/Data/MySQL/Resources/012_RegionStore.sql +++ /dev/null | |||
@@ -1,5 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE prims add index prims_parentid(ParentID); | ||
4 | |||
5 | COMMIT; \ No newline at end of file | ||
diff --git a/OpenSim/Data/MySQL/Resources/013_RegionStore.sql b/OpenSim/Data/MySQL/Resources/013_RegionStore.sql deleted file mode 100644 index a6bd30d..0000000 --- a/OpenSim/Data/MySQL/Resources/013_RegionStore.sql +++ /dev/null | |||
@@ -1,103 +0,0 @@ | |||
1 | begin; | ||
2 | |||
3 | drop table regionsettings; | ||
4 | |||
5 | CREATE TABLE `regionsettings` ( | ||
6 | `regionUUID` char(36) NOT NULL, | ||
7 | `block_terraform` int(11) NOT NULL, | ||
8 | `block_fly` int(11) NOT NULL, | ||
9 | `allow_damage` int(11) NOT NULL, | ||
10 | `restrict_pushing` int(11) NOT NULL, | ||
11 | `allow_land_resell` int(11) NOT NULL, | ||
12 | `allow_land_join_divide` int(11) NOT NULL, | ||
13 | `block_show_in_search` int(11) NOT NULL, | ||
14 | `agent_limit` int(11) NOT NULL, | ||
15 | `object_bonus` float NOT NULL, | ||
16 | `maturity` int(11) NOT NULL, | ||
17 | `disable_scripts` int(11) NOT NULL, | ||
18 | `disable_collisions` int(11) NOT NULL, | ||
19 | `disable_physics` int(11) NOT NULL, | ||
20 | `terrain_texture_1` char(36) NOT NULL, | ||
21 | `terrain_texture_2` char(36) NOT NULL, | ||
22 | `terrain_texture_3` char(36) NOT NULL, | ||
23 | `terrain_texture_4` char(36) NOT NULL, | ||
24 | `elevation_1_nw` float NOT NULL, | ||
25 | `elevation_2_nw` float NOT NULL, | ||
26 | `elevation_1_ne` float NOT NULL, | ||
27 | `elevation_2_ne` float NOT NULL, | ||
28 | `elevation_1_se` float NOT NULL, | ||
29 | `elevation_2_se` float NOT NULL, | ||
30 | `elevation_1_sw` float NOT NULL, | ||
31 | `elevation_2_sw` float NOT NULL, | ||
32 | `water_height` float NOT NULL, | ||
33 | `terrain_raise_limit` float NOT NULL, | ||
34 | `terrain_lower_limit` float NOT NULL, | ||
35 | `use_estate_sun` int(11) NOT NULL, | ||
36 | `fixed_sun` int(11) NOT NULL, | ||
37 | `sun_position` float NOT NULL, | ||
38 | `covenant` char(36) default NULL, | ||
39 | `Sandbox` tinyint(4) NOT NULL, | ||
40 | PRIMARY KEY (`regionUUID`) | ||
41 | ) ENGINE=InnoDB; | ||
42 | |||
43 | CREATE TABLE `estate_managers` ( | ||
44 | `EstateID` int(10) unsigned NOT NULL, | ||
45 | `uuid` char(36) NOT NULL, | ||
46 | KEY `EstateID` (`EstateID`) | ||
47 | ) ENGINE=InnoDB; | ||
48 | |||
49 | CREATE TABLE `estate_groups` ( | ||
50 | `EstateID` int(10) unsigned NOT NULL, | ||
51 | `uuid` char(36) NOT NULL, | ||
52 | KEY `EstateID` (`EstateID`) | ||
53 | ) ENGINE=InnoDB; | ||
54 | |||
55 | CREATE TABLE `estate_users` ( | ||
56 | `EstateID` int(10) unsigned NOT NULL, | ||
57 | `uuid` char(36) NOT NULL, | ||
58 | KEY `EstateID` (`EstateID`) | ||
59 | ) ENGINE=InnoDB; | ||
60 | |||
61 | CREATE TABLE `estateban` ( | ||
62 | `EstateID` int(10) unsigned NOT NULL, | ||
63 | `bannedUUID` varchar(36) NOT NULL, | ||
64 | `bannedIp` varchar(16) NOT NULL, | ||
65 | `bannedIpHostMask` varchar(16) NOT NULL, | ||
66 | `bannedNameMask` varchar(64) default NULL, | ||
67 | KEY `estateban_EstateID` (`EstateID`) | ||
68 | ) ENGINE=InnoDB; | ||
69 | |||
70 | CREATE TABLE `estate_settings` ( | ||
71 | `EstateID` int(10) unsigned NOT NULL auto_increment, | ||
72 | `EstateName` varchar(64) default NULL, | ||
73 | `AbuseEmailToEstateOwner` tinyint(4) NOT NULL, | ||
74 | `DenyAnonymous` tinyint(4) NOT NULL, | ||
75 | `ResetHomeOnTeleport` tinyint(4) NOT NULL, | ||
76 | `FixedSun` tinyint(4) NOT NULL, | ||
77 | `DenyTransacted` tinyint(4) NOT NULL, | ||
78 | `BlockDwell` tinyint(4) NOT NULL, | ||
79 | `DenyIdentified` tinyint(4) NOT NULL, | ||
80 | `AllowVoice` tinyint(4) NOT NULL, | ||
81 | `UseGlobalTime` tinyint(4) NOT NULL, | ||
82 | `PricePerMeter` int(11) NOT NULL, | ||
83 | `TaxFree` tinyint(4) NOT NULL, | ||
84 | `AllowDirectTeleport` tinyint(4) NOT NULL, | ||
85 | `RedirectGridX` int(11) NOT NULL, | ||
86 | `RedirectGridY` int(11) NOT NULL, | ||
87 | `ParentEstateID` int(10) unsigned NOT NULL, | ||
88 | `SunPosition` double NOT NULL, | ||
89 | `EstateSkipScripts` tinyint(4) NOT NULL, | ||
90 | `BillableFactor` float NOT NULL, | ||
91 | `PublicAccess` tinyint(4) NOT NULL, | ||
92 | PRIMARY KEY (`EstateID`) | ||
93 | ) ENGINE=InnoDB AUTO_INCREMENT=100; | ||
94 | |||
95 | CREATE TABLE `estate_map` ( | ||
96 | `RegionID` char(36) NOT NULL default '00000000-0000-0000-0000-000000000000', | ||
97 | `EstateID` int(11) NOT NULL, | ||
98 | PRIMARY KEY (`RegionID`), | ||
99 | KEY `EstateID` (`EstateID`) | ||
100 | ) ENGINE=InnoDB; | ||
101 | |||
102 | commit; | ||
103 | |||
diff --git a/OpenSim/Data/MySQL/Resources/014_RegionStore.sql b/OpenSim/Data/MySQL/Resources/014_RegionStore.sql deleted file mode 100644 index 788fd63..0000000 --- a/OpenSim/Data/MySQL/Resources/014_RegionStore.sql +++ /dev/null | |||
@@ -1,8 +0,0 @@ | |||
1 | begin; | ||
2 | |||
3 | alter table estate_settings add column AbuseEmail varchar(255) not null; | ||
4 | |||
5 | alter table estate_settings add column EstateOwner varchar(36) not null; | ||
6 | |||
7 | commit; | ||
8 | |||
diff --git a/OpenSim/Data/MySQL/Resources/015_RegionStore.sql b/OpenSim/Data/MySQL/Resources/015_RegionStore.sql deleted file mode 100644 index 6d4f9f3..0000000 --- a/OpenSim/Data/MySQL/Resources/015_RegionStore.sql +++ /dev/null | |||
@@ -1,6 +0,0 @@ | |||
1 | begin; | ||
2 | |||
3 | alter table estate_settings add column DenyMinors tinyint not null; | ||
4 | |||
5 | commit; | ||
6 | |||
diff --git a/OpenSim/Data/MySQL/Resources/016_RegionStore.sql b/OpenSim/Data/MySQL/Resources/016_RegionStore.sql deleted file mode 100644 index 9bc265e..0000000 --- a/OpenSim/Data/MySQL/Resources/016_RegionStore.sql +++ /dev/null | |||
@@ -1,27 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE prims ADD COLUMN PayPrice integer not null default 0; | ||
4 | ALTER TABLE prims ADD COLUMN PayButton1 integer not null default 0; | ||
5 | ALTER TABLE prims ADD COLUMN PayButton2 integer not null default 0; | ||
6 | ALTER TABLE prims ADD COLUMN PayButton3 integer not null default 0; | ||
7 | ALTER TABLE prims ADD COLUMN PayButton4 integer not null default 0; | ||
8 | ALTER TABLE prims ADD COLUMN LoopedSound char(36) not null default '00000000-0000-0000-0000-000000000000'; | ||
9 | ALTER TABLE prims ADD COLUMN LoopedSoundGain float not null default 0.0; | ||
10 | ALTER TABLE prims ADD COLUMN TextureAnimation blob; | ||
11 | ALTER TABLE prims ADD COLUMN OmegaX float not null default 0.0; | ||
12 | ALTER TABLE prims ADD COLUMN OmegaY float not null default 0.0; | ||
13 | ALTER TABLE prims ADD COLUMN OmegaZ float not null default 0.0; | ||
14 | ALTER TABLE prims ADD COLUMN CameraEyeOffsetX float not null default 0.0; | ||
15 | ALTER TABLE prims ADD COLUMN CameraEyeOffsetY float not null default 0.0; | ||
16 | ALTER TABLE prims ADD COLUMN CameraEyeOffsetZ float not null default 0.0; | ||
17 | ALTER TABLE prims ADD COLUMN CameraAtOffsetX float not null default 0.0; | ||
18 | ALTER TABLE prims ADD COLUMN CameraAtOffsetY float not null default 0.0; | ||
19 | ALTER TABLE prims ADD COLUMN CameraAtOffsetZ float not null default 0.0; | ||
20 | ALTER TABLE prims ADD COLUMN ForceMouselook tinyint not null default 0; | ||
21 | ALTER TABLE prims ADD COLUMN ScriptAccessPin integer not null default 0; | ||
22 | ALTER TABLE prims ADD COLUMN AllowedDrop tinyint not null default 0; | ||
23 | ALTER TABLE prims ADD COLUMN DieAtEdge tinyint not null default 0; | ||
24 | ALTER TABLE prims ADD COLUMN SalePrice integer not null default 10; | ||
25 | ALTER TABLE prims ADD COLUMN SaleType tinyint not null default 0; | ||
26 | |||
27 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/017_RegionStore.sql b/OpenSim/Data/MySQL/Resources/017_RegionStore.sql deleted file mode 100644 index 0304f30..0000000 --- a/OpenSim/Data/MySQL/Resources/017_RegionStore.sql +++ /dev/null | |||
@@ -1,9 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE prims ADD COLUMN ColorR integer not null default 0; | ||
4 | ALTER TABLE prims ADD COLUMN ColorG integer not null default 0; | ||
5 | ALTER TABLE prims ADD COLUMN ColorB integer not null default 0; | ||
6 | ALTER TABLE prims ADD COLUMN ColorA integer not null default 0; | ||
7 | ALTER TABLE prims ADD COLUMN ParticleSystem blob; | ||
8 | |||
9 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/018_RegionStore.sql b/OpenSim/Data/MySQL/Resources/018_RegionStore.sql deleted file mode 100644 index 68c489c..0000000 --- a/OpenSim/Data/MySQL/Resources/018_RegionStore.sql +++ /dev/null | |||
@@ -1,6 +0,0 @@ | |||
1 | begin; | ||
2 | |||
3 | ALTER TABLE prims ADD COLUMN ClickAction tinyint NOT NULL default 0; | ||
4 | |||
5 | commit; | ||
6 | |||
diff --git a/OpenSim/Data/MySQL/Resources/019_RegionStore.sql b/OpenSim/Data/MySQL/Resources/019_RegionStore.sql deleted file mode 100644 index 4c14f2a..0000000 --- a/OpenSim/Data/MySQL/Resources/019_RegionStore.sql +++ /dev/null | |||
@@ -1,6 +0,0 @@ | |||
1 | begin; | ||
2 | |||
3 | ALTER TABLE prims ADD COLUMN Material tinyint NOT NULL default 3; | ||
4 | |||
5 | commit; | ||
6 | |||
diff --git a/OpenSim/Data/MySQL/Resources/020_RegionStore.sql b/OpenSim/Data/MySQL/Resources/020_RegionStore.sql deleted file mode 100644 index 814ef48..0000000 --- a/OpenSim/Data/MySQL/Resources/020_RegionStore.sql +++ /dev/null | |||
@@ -1,7 +0,0 @@ | |||
1 | begin; | ||
2 | |||
3 | ALTER TABLE land ADD COLUMN OtherCleanTime integer NOT NULL default 0; | ||
4 | ALTER TABLE land ADD COLUMN Dwell integer NOT NULL default 0; | ||
5 | |||
6 | commit; | ||
7 | |||
diff --git a/OpenSim/Data/MySQL/Resources/021_RegionStore.sql b/OpenSim/Data/MySQL/Resources/021_RegionStore.sql deleted file mode 100644 index c59b27e..0000000 --- a/OpenSim/Data/MySQL/Resources/021_RegionStore.sql +++ /dev/null | |||
@@ -1,8 +0,0 @@ | |||
1 | begin; | ||
2 | |||
3 | ALTER TABLE regionsettings ADD COLUMN sunvectorx double NOT NULL default 0; | ||
4 | ALTER TABLE regionsettings ADD COLUMN sunvectory double NOT NULL default 0; | ||
5 | ALTER TABLE regionsettings ADD COLUMN sunvectorz double NOT NULL default 0; | ||
6 | |||
7 | commit; | ||
8 | |||
diff --git a/OpenSim/Data/MySQL/Resources/022_RegionStore.sql b/OpenSim/Data/MySQL/Resources/022_RegionStore.sql deleted file mode 100644 index df0bb7d..0000000 --- a/OpenSim/Data/MySQL/Resources/022_RegionStore.sql +++ /dev/null | |||
@@ -1,6 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE prims ADD COLUMN CollisionSound char(36) not null default '00000000-0000-0000-0000-000000000000'; | ||
4 | ALTER TABLE prims ADD COLUMN CollisionSoundVolume float not null default 0.0; | ||
5 | |||
6 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/023_RegionStore.sql b/OpenSim/Data/MySQL/Resources/023_RegionStore.sql deleted file mode 100644 index 559591f..0000000 --- a/OpenSim/Data/MySQL/Resources/023_RegionStore.sql +++ /dev/null | |||
@@ -1,6 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE prims ADD COLUMN LinkNumber integer not null default 0; | ||
4 | |||
5 | COMMIT; | ||
6 | |||
diff --git a/OpenSim/Data/MySQL/Resources/024_RegionStore.sql b/OpenSim/Data/MySQL/Resources/024_RegionStore.sql deleted file mode 100644 index defbf5c..0000000 --- a/OpenSim/Data/MySQL/Resources/024_RegionStore.sql +++ /dev/null | |||
@@ -1,18 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | alter table regionsettings change column `object_bonus` `object_bonus` double NOT NULL; | ||
4 | alter table regionsettings change column `elevation_1_nw` `elevation_1_nw` double NOT NULL; | ||
5 | alter table regionsettings change column `elevation_2_nw` `elevation_2_nw` double NOT NULL; | ||
6 | alter table regionsettings change column `elevation_1_ne` `elevation_1_ne` double NOT NULL; | ||
7 | alter table regionsettings change column `elevation_2_ne` `elevation_2_ne` double NOT NULL; | ||
8 | alter table regionsettings change column `elevation_1_se` `elevation_1_se` double NOT NULL; | ||
9 | alter table regionsettings change column `elevation_2_se` `elevation_2_se` double NOT NULL; | ||
10 | alter table regionsettings change column `elevation_1_sw` `elevation_1_sw` double NOT NULL; | ||
11 | alter table regionsettings change column `elevation_2_sw` `elevation_2_sw` double NOT NULL; | ||
12 | alter table regionsettings change column `water_height` `water_height` double NOT NULL; | ||
13 | alter table regionsettings change column `terrain_raise_limit` `terrain_raise_limit` double NOT NULL; | ||
14 | alter table regionsettings change column `terrain_lower_limit` `terrain_lower_limit` double NOT NULL; | ||
15 | alter table regionsettings change column `sun_position` `sun_position` double NOT NULL; | ||
16 | |||
17 | COMMIT; | ||
18 | |||
diff --git a/OpenSim/Data/MySQL/Resources/025_RegionStore.sql b/OpenSim/Data/MySQL/Resources/025_RegionStore.sql deleted file mode 100644 index e8f5d70..0000000 --- a/OpenSim/Data/MySQL/Resources/025_RegionStore.sql +++ /dev/null | |||
@@ -1,46 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | alter table prims change column `PositionX` `PositionX` double default NULL; | ||
4 | alter table prims change column `PositionY` `PositionY` double default NULL; | ||
5 | alter table prims change column `PositionZ` `PositionZ` double default NULL; | ||
6 | alter table prims change column `GroupPositionX` `GroupPositionX` double default NULL; | ||
7 | alter table prims change column `GroupPositionY` `GroupPositionY` double default NULL; | ||
8 | alter table prims change column `GroupPositionZ` `GroupPositionZ` double default NULL; | ||
9 | alter table prims change column `VelocityX` `VelocityX` double default NULL; | ||
10 | alter table prims change column `VelocityY` `VelocityY` double default NULL; | ||
11 | alter table prims change column `VelocityZ` `VelocityZ` double default NULL; | ||
12 | alter table prims change column `AngularVelocityX` `AngularVelocityX` double default NULL; | ||
13 | alter table prims change column `AngularVelocityY` `AngularVelocityY` double default NULL; | ||
14 | alter table prims change column `AngularVelocityZ` `AngularVelocityZ` double default NULL; | ||
15 | alter table prims change column `AccelerationX` `AccelerationX` double default NULL; | ||
16 | alter table prims change column `AccelerationY` `AccelerationY` double default NULL; | ||
17 | alter table prims change column `AccelerationZ` `AccelerationZ` double default NULL; | ||
18 | alter table prims change column `RotationX` `RotationX` double default NULL; | ||
19 | alter table prims change column `RotationY` `RotationY` double default NULL; | ||
20 | alter table prims change column `RotationZ` `RotationZ` double default NULL; | ||
21 | alter table prims change column `RotationW` `RotationW` double default NULL; | ||
22 | alter table prims change column `SitTargetOffsetX` `SitTargetOffsetX` double default NULL; | ||
23 | alter table prims change column `SitTargetOffsetY` `SitTargetOffsetY` double default NULL; | ||
24 | alter table prims change column `SitTargetOffsetZ` `SitTargetOffsetZ` double default NULL; | ||
25 | alter table prims change column `SitTargetOrientW` `SitTargetOrientW` double default NULL; | ||
26 | alter table prims change column `SitTargetOrientX` `SitTargetOrientX` double default NULL; | ||
27 | alter table prims change column `SitTargetOrientY` `SitTargetOrientY` double default NULL; | ||
28 | alter table prims change column `SitTargetOrientZ` `SitTargetOrientZ` double default NULL; | ||
29 | alter table prims change column `LoopedSoundGain` `LoopedSoundGain` double NOT NULL default '0'; | ||
30 | alter table prims change column `OmegaX` `OmegaX` double NOT NULL default '0'; | ||
31 | alter table prims change column `OmegaY` `OmegaY` double NOT NULL default '0'; | ||
32 | alter table prims change column `OmegaZ` `OmegaZ` double NOT NULL default '0'; | ||
33 | alter table prims change column `CameraEyeOffsetX` `CameraEyeOffsetX` double NOT NULL default '0'; | ||
34 | alter table prims change column `CameraEyeOffsetY` `CameraEyeOffsetY` double NOT NULL default '0'; | ||
35 | alter table prims change column `CameraEyeOffsetZ` `CameraEyeOffsetZ` double NOT NULL default '0'; | ||
36 | alter table prims change column `CameraAtOffsetX` `CameraAtOffsetX` double NOT NULL default '0'; | ||
37 | alter table prims change column `CameraAtOffsetY` `CameraAtOffsetY` double NOT NULL default '0'; | ||
38 | alter table prims change column `CameraAtOffsetZ` `CameraAtOffsetZ` double NOT NULL default '0'; | ||
39 | alter table prims change column `CollisionSoundVolume` `CollisionSoundVolume` double NOT NULL default '0'; | ||
40 | |||
41 | alter table primshapes change column `ScaleX` `ScaleX` double NOT NULL default '0'; | ||
42 | alter table primshapes change column `ScaleY` `ScaleY` double NOT NULL default '0'; | ||
43 | alter table primshapes change column `ScaleZ` `ScaleZ` double NOT NULL default '0'; | ||
44 | |||
45 | COMMIT; | ||
46 | |||
diff --git a/OpenSim/Data/MySQL/Resources/026_RegionStore.sql b/OpenSim/Data/MySQL/Resources/026_RegionStore.sql deleted file mode 100644 index 91af8a8..0000000 --- a/OpenSim/Data/MySQL/Resources/026_RegionStore.sql +++ /dev/null | |||
@@ -1,41 +0,0 @@ | |||
1 | begin; | ||
2 | |||
3 | alter table prims change column `PositionX` `PositionX` double default NULL; | ||
4 | alter table prims change column `PositionY` `PositionY` double default NULL; | ||
5 | alter table prims change column `PositionZ` `PositionZ` double default NULL; | ||
6 | alter table prims change column `GroupPositionX` `GroupPositionX` double default NULL; | ||
7 | alter table prims change column `GroupPositionY` `GroupPositionY` double default NULL; | ||
8 | alter table prims change column `GroupPositionZ` `GroupPositionZ` double default NULL; | ||
9 | alter table prims change column `VelocityX` `VelocityX` double default NULL; | ||
10 | alter table prims change column `VelocityY` `VelocityY` double default NULL; | ||
11 | alter table prims change column `VelocityZ` `VelocityZ` double default NULL; | ||
12 | alter table prims change column `AngularVelocityX` `AngularVelocityX` double default NULL; | ||
13 | alter table prims change column `AngularVelocityY` `AngularVelocityY` double default NULL; | ||
14 | alter table prims change column `AngularVelocityZ` `AngularVelocityZ` double default NULL; | ||
15 | alter table prims change column `AccelerationX` `AccelerationX` double default NULL; | ||
16 | alter table prims change column `AccelerationY` `AccelerationY` double default NULL; | ||
17 | alter table prims change column `AccelerationZ` `AccelerationZ` double default NULL; | ||
18 | alter table prims change column `RotationX` `RotationX` double default NULL; | ||
19 | alter table prims change column `RotationY` `RotationY` double default NULL; | ||
20 | alter table prims change column `RotationZ` `RotationZ` double default NULL; | ||
21 | alter table prims change column `RotationW` `RotationW` double default NULL; | ||
22 | alter table prims change column `SitTargetOffsetX` `SitTargetOffsetX` double default NULL; | ||
23 | alter table prims change column `SitTargetOffsetY` `SitTargetOffsetY` double default NULL; | ||
24 | alter table prims change column `SitTargetOffsetZ` `SitTargetOffsetZ` double default NULL; | ||
25 | alter table prims change column `SitTargetOrientW` `SitTargetOrientW` double default NULL; | ||
26 | alter table prims change column `SitTargetOrientX` `SitTargetOrientX` double default NULL; | ||
27 | alter table prims change column `SitTargetOrientY` `SitTargetOrientY` double default NULL; | ||
28 | alter table prims change column `SitTargetOrientZ` `SitTargetOrientZ` double default NULL; | ||
29 | alter table prims change column `LoopedSoundGain` `LoopedSoundGain` double NOT NULL default '0'; | ||
30 | alter table prims change column `OmegaX` `OmegaX` double NOT NULL default '0'; | ||
31 | alter table prims change column `OmegaY` `OmegaY` double NOT NULL default '0'; | ||
32 | alter table prims change column `OmegaZ` `OmegaZ` double NOT NULL default '0'; | ||
33 | alter table prims change column `CameraEyeOffsetX` `CameraEyeOffsetX` double NOT NULL default '0'; | ||
34 | alter table prims change column `CameraEyeOffsetY` `CameraEyeOffsetY` double NOT NULL default '0'; | ||
35 | alter table prims change column `CameraEyeOffsetZ` `CameraEyeOffsetZ` double NOT NULL default '0'; | ||
36 | alter table prims change column `CameraAtOffsetX` `CameraAtOffsetX` double NOT NULL default '0'; | ||
37 | alter table prims change column `CameraAtOffsetY` `CameraAtOffsetY` double NOT NULL default '0'; | ||
38 | alter table prims change column `CameraAtOffsetZ` `CameraAtOffsetZ` double NOT NULL default '0'; | ||
39 | alter table prims change column `CollisionSoundVolume` `CollisionSoundVolume` double NOT NULL default '0'; | ||
40 | |||
41 | commit; | ||
diff --git a/OpenSim/Data/MySQL/Resources/027_RegionStore.sql b/OpenSim/Data/MySQL/Resources/027_RegionStore.sql deleted file mode 100644 index e1efab3..0000000 --- a/OpenSim/Data/MySQL/Resources/027_RegionStore.sql +++ /dev/null | |||
@@ -1,5 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE prims DROP COLUMN ParentID; | ||
4 | |||
5 | COMMIT; \ No newline at end of file | ||
diff --git a/OpenSim/Data/MySQL/Resources/028_RegionStore.sql b/OpenSim/Data/MySQL/Resources/028_RegionStore.sql deleted file mode 100644 index 078394f..0000000 --- a/OpenSim/Data/MySQL/Resources/028_RegionStore.sql +++ /dev/null | |||
@@ -1,79 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | update terrain | ||
4 | set RegionUUID = concat(substr(RegionUUID, 1, 8), "-", substr(RegionUUID, 9, 4), "-", substr(RegionUUID, 13, 4), "-", substr(RegionUUID, 17, 4), "-", substr(RegionUUID, 21, 12)) | ||
5 | where RegionUUID not like '%-%'; | ||
6 | |||
7 | |||
8 | update landaccesslist | ||
9 | set LandUUID = concat(substr(LandUUID, 1, 8), "-", substr(LandUUID, 9, 4), "-", substr(LandUUID, 13, 4), "-", substr(LandUUID, 17, 4), "-", substr(LandUUID, 21, 12)) | ||
10 | where LandUUID not like '%-%'; | ||
11 | |||
12 | update landaccesslist | ||
13 | set AccessUUID = concat(substr(AccessUUID, 1, 8), "-", substr(AccessUUID, 9, 4), "-", substr(AccessUUID, 13, 4), "-", substr(AccessUUID, 17, 4), "-", substr(AccessUUID, 21, 12)) | ||
14 | where AccessUUID not like '%-%'; | ||
15 | |||
16 | |||
17 | update prims | ||
18 | set UUID = concat(substr(UUID, 1, 8), "-", substr(UUID, 9, 4), "-", substr(UUID, 13, 4), "-", substr(UUID, 17, 4), "-", substr(UUID, 21, 12)) | ||
19 | where UUID not like '%-%'; | ||
20 | |||
21 | update prims | ||
22 | set RegionUUID = concat(substr(RegionUUID, 1, 8), "-", substr(RegionUUID, 9, 4), "-", substr(RegionUUID, 13, 4), "-", substr(RegionUUID, 17, 4), "-", substr(RegionUUID, 21, 12)) | ||
23 | where RegionUUID not like '%-%'; | ||
24 | |||
25 | update prims | ||
26 | set SceneGroupID = concat(substr(SceneGroupID, 1, 8), "-", substr(SceneGroupID, 9, 4), "-", substr(SceneGroupID, 13, 4), "-", substr(SceneGroupID, 17, 4), "-", substr(SceneGroupID, 21, 12)) | ||
27 | where SceneGroupID not like '%-%'; | ||
28 | |||
29 | update prims | ||
30 | set CreatorID = concat(substr(CreatorID, 1, 8), "-", substr(CreatorID, 9, 4), "-", substr(CreatorID, 13, 4), "-", substr(CreatorID, 17, 4), "-", substr(CreatorID, 21, 12)) | ||
31 | where CreatorID not like '%-%'; | ||
32 | |||
33 | update prims | ||
34 | set OwnerID = concat(substr(OwnerID, 1, 8), "-", substr(OwnerID, 9, 4), "-", substr(OwnerID, 13, 4), "-", substr(OwnerID, 17, 4), "-", substr(OwnerID, 21, 12)) | ||
35 | where OwnerID not like '%-%'; | ||
36 | |||
37 | update prims | ||
38 | set GroupID = concat(substr(GroupID, 1, 8), "-", substr(GroupID, 9, 4), "-", substr(GroupID, 13, 4), "-", substr(GroupID, 17, 4), "-", substr(GroupID, 21, 12)) | ||
39 | where GroupID not like '%-%'; | ||
40 | |||
41 | update prims | ||
42 | set LastOwnerID = concat(substr(LastOwnerID, 1, 8), "-", substr(LastOwnerID, 9, 4), "-", substr(LastOwnerID, 13, 4), "-", substr(LastOwnerID, 17, 4), "-", substr(LastOwnerID, 21, 12)) | ||
43 | where LastOwnerID not like '%-%'; | ||
44 | |||
45 | |||
46 | update primshapes | ||
47 | set UUID = concat(substr(UUID, 1, 8), "-", substr(UUID, 9, 4), "-", substr(UUID, 13, 4), "-", substr(UUID, 17, 4), "-", substr(UUID, 21, 12)) | ||
48 | where UUID not like '%-%'; | ||
49 | |||
50 | |||
51 | update land | ||
52 | set UUID = concat(substr(UUID, 1, 8), "-", substr(UUID, 9, 4), "-", substr(UUID, 13, 4), "-", substr(UUID, 17, 4), "-", substr(UUID, 21, 12)) | ||
53 | where UUID not like '%-%'; | ||
54 | |||
55 | update land | ||
56 | set RegionUUID = concat(substr(RegionUUID, 1, 8), "-", substr(RegionUUID, 9, 4), "-", substr(RegionUUID, 13, 4), "-", substr(RegionUUID, 17, 4), "-", substr(RegionUUID, 21, 12)) | ||
57 | where RegionUUID not like '%-%'; | ||
58 | |||
59 | update land | ||
60 | set OwnerUUID = concat(substr(OwnerUUID, 1, 8), "-", substr(OwnerUUID, 9, 4), "-", substr(OwnerUUID, 13, 4), "-", substr(OwnerUUID, 17, 4), "-", substr(OwnerUUID, 21, 12)) | ||
61 | where OwnerUUID not like '%-%'; | ||
62 | |||
63 | update land | ||
64 | set GroupUUID = concat(substr(GroupUUID, 1, 8), "-", substr(GroupUUID, 9, 4), "-", substr(GroupUUID, 13, 4), "-", substr(GroupUUID, 17, 4), "-", substr(GroupUUID, 21, 12)) | ||
65 | where GroupUUID not like '%-%'; | ||
66 | |||
67 | update land | ||
68 | set MediaTextureUUID = concat(substr(MediaTextureUUID, 1, 8), "-", substr(MediaTextureUUID, 9, 4), "-", substr(MediaTextureUUID, 13, 4), "-", substr(MediaTextureUUID, 17, 4), "-", substr(MediaTextureUUID, 21, 12)) | ||
69 | where MediaTextureUUID not like '%-%'; | ||
70 | |||
71 | update land | ||
72 | set SnapshotUUID = concat(substr(SnapshotUUID, 1, 8), "-", substr(SnapshotUUID, 9, 4), "-", substr(SnapshotUUID, 13, 4), "-", substr(SnapshotUUID, 17, 4), "-", substr(SnapshotUUID, 21, 12)) | ||
73 | where SnapshotUUID not like '%-%'; | ||
74 | |||
75 | update land | ||
76 | set AuthbuyerID = concat(substr(AuthbuyerID, 1, 8), "-", substr(AuthbuyerID, 9, 4), "-", substr(AuthbuyerID, 13, 4), "-", substr(AuthbuyerID, 17, 4), "-", substr(AuthbuyerID, 21, 12)) | ||
77 | where AuthbuyerID not like '%-%'; | ||
78 | |||
79 | COMMIT; \ No newline at end of file | ||
diff --git a/OpenSim/Data/MySQL/Resources/029_RegionStore.sql b/OpenSim/Data/MySQL/Resources/029_RegionStore.sql deleted file mode 100644 index b5962a2..0000000 --- a/OpenSim/Data/MySQL/Resources/029_RegionStore.sql +++ /dev/null | |||
@@ -1,5 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE prims ADD COLUMN PassTouches tinyint not null default 0; | ||
4 | |||
5 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/030_RegionStore.sql b/OpenSim/Data/MySQL/Resources/030_RegionStore.sql deleted file mode 100644 index dfdcf6d..0000000 --- a/OpenSim/Data/MySQL/Resources/030_RegionStore.sql +++ /dev/null | |||
@@ -1,7 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE regionsettings ADD COLUMN loaded_creation_date varchar(20) default NULL; | ||
4 | ALTER TABLE regionsettings ADD COLUMN loaded_creation_time varchar(20) default NULL; | ||
5 | ALTER TABLE regionsettings ADD COLUMN loaded_creation_id varchar(64) default NULL; | ||
6 | |||
7 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/031_RegionStore.sql b/OpenSim/Data/MySQL/Resources/031_RegionStore.sql deleted file mode 100644 index d069296..0000000 --- a/OpenSim/Data/MySQL/Resources/031_RegionStore.sql +++ /dev/null | |||
@@ -1,7 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | ALTER TABLE regionsettings DROP COLUMN loaded_creation_date; | ||
4 | ALTER TABLE regionsettings DROP COLUMN loaded_creation_time; | ||
5 | ALTER TABLE regionsettings ADD COLUMN loaded_creation_datetime int unsigned NOT NULL default 0; | ||
6 | |||
7 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/032_RegionStore.sql b/OpenSim/Data/MySQL/Resources/032_RegionStore.sql deleted file mode 100644 index 02ac1f5..0000000 --- a/OpenSim/Data/MySQL/Resources/032_RegionStore.sql +++ /dev/null | |||
@@ -1,71 +0,0 @@ | |||
1 | BEGIN; | ||
2 | |||
3 | CREATE TABLE `regionwindlight` ( | ||
4 | `region_id` varchar(36) NOT NULL DEFAULT '000000-0000-0000-0000-000000000000', | ||
5 | `water_color_r` float(9,6) unsigned NOT NULL DEFAULT '4.000000', | ||
6 | `water_color_g` float(9,6) unsigned NOT NULL DEFAULT '38.000000', | ||
7 | `water_color_b` float(9,6) unsigned NOT NULL DEFAULT '64.000000', | ||
8 | `water_fog_density_exponent` float(3,1) unsigned NOT NULL DEFAULT '4.0', | ||
9 | `underwater_fog_modifier` float(3,2) unsigned NOT NULL DEFAULT '0.25', | ||
10 | `reflection_wavelet_scale_1` float(3,1) unsigned NOT NULL DEFAULT '2.0', | ||
11 | `reflection_wavelet_scale_2` float(3,1) unsigned NOT NULL DEFAULT '2.0', | ||
12 | `reflection_wavelet_scale_3` float(3,1) unsigned NOT NULL DEFAULT '2.0', | ||
13 | `fresnel_scale` float(3,2) unsigned NOT NULL DEFAULT '0.40', | ||
14 | `fresnel_offset` float(3,2) unsigned NOT NULL DEFAULT '0.50', | ||
15 | `refract_scale_above` float(3,2) unsigned NOT NULL DEFAULT '0.03', | ||
16 | `refract_scale_below` float(3,2) unsigned NOT NULL DEFAULT '0.20', | ||
17 | `blur_multiplier` float(4,3) unsigned NOT NULL DEFAULT '0.040', | ||
18 | `big_wave_direction_x` float(3,2) NOT NULL DEFAULT '1.05', | ||
19 | `big_wave_direction_y` float(3,2) NOT NULL DEFAULT '-0.42', | ||
20 | `little_wave_direction_x` float(3,2) NOT NULL DEFAULT '1.11', | ||
21 | `little_wave_direction_y` float(3,2) NOT NULL DEFAULT '-1.16', | ||
22 | `normal_map_texture` varchar(36) NOT NULL DEFAULT '822ded49-9a6c-f61c-cb89-6df54f42cdf4', | ||
23 | `horizon_r` float(3,2) unsigned NOT NULL DEFAULT '0.25', | ||
24 | `horizon_g` float(3,2) unsigned NOT NULL DEFAULT '0.25', | ||
25 | `horizon_b` float(3,2) unsigned NOT NULL DEFAULT '0.32', | ||
26 | `horizon_i` float(3,2) unsigned NOT NULL DEFAULT '0.32', | ||
27 | `haze_horizon` float(3,2) unsigned NOT NULL DEFAULT '0.19', | ||
28 | `blue_density_r` float(3,2) unsigned NOT NULL DEFAULT '0.12', | ||
29 | `blue_density_g` float(3,2) unsigned NOT NULL DEFAULT '0.22', | ||
30 | `blue_density_b` float(3,2) unsigned NOT NULL DEFAULT '0.38', | ||
31 | `blue_density_i` float(3,2) unsigned NOT NULL DEFAULT '0.38', | ||
32 | `haze_density` float(3,2) unsigned NOT NULL DEFAULT '0.70', | ||
33 | `density_multiplier` float(3,2) unsigned NOT NULL DEFAULT '0.18', | ||
34 | `distance_multiplier` float(4,1) unsigned NOT NULL DEFAULT '0.8', | ||
35 | `max_altitude` int(4) unsigned NOT NULL DEFAULT '1605', | ||
36 | `sun_moon_color_r` float(3,2) unsigned NOT NULL DEFAULT '0.24', | ||
37 | `sun_moon_color_g` float(3,2) unsigned NOT NULL DEFAULT '0.26', | ||
38 | `sun_moon_color_b` float(3,2) unsigned NOT NULL DEFAULT '0.30', | ||
39 | `sun_moon_color_i` float(3,2) unsigned NOT NULL DEFAULT '0.30', | ||
40 | `sun_moon_position` float(4,3) unsigned NOT NULL DEFAULT '0.317', | ||
41 | `ambient_r` float(3,2) unsigned NOT NULL DEFAULT '0.35', | ||
42 | `ambient_g` float(3,2) unsigned NOT NULL DEFAULT '0.35', | ||
43 | `ambient_b` float(3,2) unsigned NOT NULL DEFAULT '0.35', | ||
44 | `ambient_i` float(3,2) unsigned NOT NULL DEFAULT '0.35', | ||
45 | `east_angle` float(3,2) unsigned NOT NULL DEFAULT '0.00', | ||
46 | `sun_glow_focus` float(3,2) unsigned NOT NULL DEFAULT '0.10', | ||
47 | `sun_glow_size` float(3,2) unsigned NOT NULL DEFAULT '1.75', | ||
48 | `scene_gamma` float(4,2) unsigned NOT NULL DEFAULT '1.00', | ||
49 | `star_brightness` float(3,2) unsigned NOT NULL DEFAULT '0.00', | ||
50 | `cloud_color_r` float(3,2) unsigned NOT NULL DEFAULT '0.41', | ||
51 | `cloud_color_g` float(3,2) unsigned NOT NULL DEFAULT '0.41', | ||
52 | `cloud_color_b` float(3,2) unsigned NOT NULL DEFAULT '0.41', | ||
53 | `cloud_color_i` float(3,2) unsigned NOT NULL DEFAULT '0.41', | ||
54 | `cloud_x` float(3,2) unsigned NOT NULL DEFAULT '1.00', | ||
55 | `cloud_y` float(3,2) unsigned NOT NULL DEFAULT '0.53', | ||
56 | `cloud_density` float(3,2) unsigned NOT NULL DEFAULT '1.00', | ||
57 | `cloud_coverage` float(3,2) unsigned NOT NULL DEFAULT '0.27', | ||
58 | `cloud_scale` float(3,2) unsigned NOT NULL DEFAULT '0.42', | ||
59 | `cloud_detail_x` float(3,2) unsigned NOT NULL DEFAULT '1.00', | ||
60 | `cloud_detail_y` float(3,2) unsigned NOT NULL DEFAULT '0.53', | ||
61 | `cloud_detail_density` float(3,2) unsigned NOT NULL DEFAULT '0.12', | ||
62 | `cloud_scroll_x` float(3,2) unsigned NOT NULL DEFAULT '0.20', | ||
63 | `cloud_scroll_x_lock` tinyint(1) unsigned NOT NULL DEFAULT '0', | ||
64 | `cloud_scroll_y` float(3,2) unsigned NOT NULL DEFAULT '0.01', | ||
65 | `cloud_scroll_y_lock` tinyint(1) unsigned NOT NULL DEFAULT '0', | ||
66 | `draw_classic_clouds` tinyint(1) unsigned NOT NULL DEFAULT '1', | ||
67 | PRIMARY KEY (`region_id`) | ||
68 | ); | ||
69 | |||
70 | ALTER TABLE estate_settings AUTO_INCREMENT = 100; | ||
71 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/033_RegionStore.sql b/OpenSim/Data/MySQL/Resources/033_RegionStore.sql deleted file mode 100644 index 2832b41..0000000 --- a/OpenSim/Data/MySQL/Resources/033_RegionStore.sql +++ /dev/null | |||
@@ -1,3 +0,0 @@ | |||
1 | BEGIN; | ||
2 | ALTER TABLE regionsettings ADD map_tile_ID CHAR(36) NOT NULL DEFAULT '00000000-0000-0000-0000-000000000000'; | ||
3 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/AssetStore.migrations b/OpenSim/Data/MySQL/Resources/AssetStore.migrations new file mode 100644 index 0000000..3fd58b7 --- /dev/null +++ b/OpenSim/Data/MySQL/Resources/AssetStore.migrations | |||
@@ -0,0 +1,77 @@ | |||
1 | # ----------------- | ||
2 | :VERSION 1 | ||
3 | |||
4 | BEGIN; | ||
5 | |||
6 | CREATE TABLE `assets` ( | ||
7 | `id` binary(16) NOT NULL, | ||
8 | `name` varchar(64) NOT NULL, | ||
9 | `description` varchar(64) NOT NULL, | ||
10 | `assetType` tinyint(4) NOT NULL, | ||
11 | `invType` tinyint(4) NOT NULL, | ||
12 | `local` tinyint(1) NOT NULL, | ||
13 | `temporary` tinyint(1) NOT NULL, | ||
14 | `data` longblob NOT NULL, | ||
15 | PRIMARY KEY (`id`) | ||
16 | ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Rev. 1'; | ||
17 | |||
18 | COMMIT; | ||
19 | |||
20 | # ----------------- | ||
21 | :VERSION 2 | ||
22 | |||
23 | BEGIN; | ||
24 | |||
25 | ALTER TABLE assets change id oldid binary(16); | ||
26 | ALTER TABLE assets add id varchar(36) not null default ''; | ||
27 | UPDATE assets set id = concat(substr(hex(oldid),1,8),"-",substr(hex(oldid),9,4),"-",substr(hex(oldid),13,4),"-",substr(hex(oldid),17,4),"-",substr(hex(oldid),21,12)); | ||
28 | ALTER TABLE assets drop oldid; | ||
29 | ALTER TABLE assets add constraint primary key(id); | ||
30 | |||
31 | COMMIT; | ||
32 | |||
33 | # ----------------- | ||
34 | :VERSION 3 | ||
35 | |||
36 | BEGIN; | ||
37 | |||
38 | ALTER TABLE assets change id oldid varchar(36); | ||
39 | ALTER TABLE assets add id char(36) not null default '00000000-0000-0000-0000-000000000000'; | ||
40 | UPDATE assets set id = oldid; | ||
41 | ALTER TABLE assets drop oldid; | ||
42 | ALTER TABLE assets add constraint primary key(id); | ||
43 | |||
44 | COMMIT; | ||
45 | |||
46 | # ----------------- | ||
47 | :VERSION 4 | ||
48 | |||
49 | BEGIN; | ||
50 | |||
51 | ALTER TABLE assets drop InvType; | ||
52 | |||
53 | COMMIT; | ||
54 | |||
55 | # ----------------- | ||
56 | :VERSION 5 | ||
57 | |||
58 | BEGIN; | ||
59 | |||
60 | ALTER TABLE assets add create_time integer default 0; | ||
61 | ALTER TABLE assets add access_time integer default 0; | ||
62 | |||
63 | COMMIT; | ||
64 | |||
65 | # ----------------- | ||
66 | :VERSION 6 | ||
67 | |||
68 | DELETE FROM assets WHERE id = 'dc4b9f0b-d008-45c6-96a4-01dd947ac621' | ||
69 | |||
70 | :VERSION 7 | ||
71 | |||
72 | ALTER TABLE assets ADD COLUMN asset_flags INTEGER NOT NULL DEFAULT 0; | ||
73 | |||
74 | :VERSION 8 | ||
75 | |||
76 | alter table assets add CreatorID varchar(36) not null default '' | ||
77 | |||
diff --git a/OpenSim/Data/MySQL/Resources/001_AuthStore.sql b/OpenSim/Data/MySQL/Resources/AuthStore.migrations index c7e16fb..023c786 100644 --- a/OpenSim/Data/MySQL/Resources/001_AuthStore.sql +++ b/OpenSim/Data/MySQL/Resources/AuthStore.migrations | |||
@@ -1,3 +1,5 @@ | |||
1 | :VERSION 1 # ------------------------------- | ||
2 | |||
1 | begin; | 3 | begin; |
2 | 4 | ||
3 | CREATE TABLE `auth` ( | 5 | CREATE TABLE `auth` ( |
@@ -19,3 +21,19 @@ CREATE TABLE `tokens` ( | |||
19 | ) ENGINE=InnoDB; | 21 | ) ENGINE=InnoDB; |
20 | 22 | ||
21 | commit; | 23 | commit; |
24 | |||
25 | :VERSION 2 # ------------------------------- | ||
26 | |||
27 | BEGIN; | ||
28 | |||
29 | INSERT INTO auth (UUID, passwordHash, passwordSalt, webLoginKey) SELECT `UUID` AS UUID, `passwordHash` AS passwordHash, `passwordSalt` AS passwordSalt, `webLoginKey` AS webLoginKey FROM users; | ||
30 | |||
31 | COMMIT; | ||
32 | |||
33 | :VERSION 3 # ------------------------------- | ||
34 | |||
35 | BEGIN; | ||
36 | |||
37 | ALTER TABLE `auth` ADD COLUMN `accountType` VARCHAR(32) NOT NULL DEFAULT 'UserAccount'; | ||
38 | |||
39 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/Avatar.migrations b/OpenSim/Data/MySQL/Resources/Avatar.migrations new file mode 100644 index 0000000..8d0eee6 --- /dev/null +++ b/OpenSim/Data/MySQL/Resources/Avatar.migrations | |||
@@ -0,0 +1,12 @@ | |||
1 | :VERSION 1 | ||
2 | |||
3 | BEGIN; | ||
4 | |||
5 | CREATE TABLE Avatars ( | ||
6 | PrincipalID CHAR(36) NOT NULL, | ||
7 | Name VARCHAR(32) NOT NULL, | ||
8 | Value VARCHAR(255) NOT NULL DEFAULT '', | ||
9 | PRIMARY KEY(PrincipalID, Name), | ||
10 | KEY(PrincipalID)); | ||
11 | |||
12 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/FriendsStore.migrations b/OpenSim/Data/MySQL/Resources/FriendsStore.migrations new file mode 100644 index 0000000..ce713bd --- /dev/null +++ b/OpenSim/Data/MySQL/Resources/FriendsStore.migrations | |||
@@ -0,0 +1,25 @@ | |||
1 | :VERSION 1 # ------------------------- | ||
2 | |||
3 | BEGIN; | ||
4 | |||
5 | CREATE TABLE `Friends` ( | ||
6 | `PrincipalID` CHAR(36) NOT NULL, | ||
7 | `Friend` VARCHAR(255) NOT NULL, | ||
8 | `Flags` VARCHAR(16) NOT NULL DEFAULT 0, | ||
9 | `Offered` VARCHAR(32) NOT NULL DEFAULT 0, | ||
10 | PRIMARY KEY(`PrincipalID`, `Friend`), | ||
11 | KEY(`PrincipalID`) | ||
12 | ); | ||
13 | |||
14 | COMMIT; | ||
15 | |||
16 | :VERSION 2 # ------------------------- | ||
17 | |||
18 | BEGIN; | ||
19 | |||
20 | INSERT INTO `Friends` SELECT `ownerID`, `friendID`, `friendPerms`, 0 FROM `userfriends`; | ||
21 | |||
22 | COMMIT; | ||
23 | |||
24 | |||
25 | |||
diff --git a/OpenSim/Data/MySQL/Resources/001_GridStore.sql b/OpenSim/Data/MySQL/Resources/GridStore.migrations index cb0f9bd..523a8ac 100644 --- a/OpenSim/Data/MySQL/Resources/001_GridStore.sql +++ b/OpenSim/Data/MySQL/Resources/GridStore.migrations | |||
@@ -1,3 +1,5 @@ | |||
1 | :VERSION 1 | ||
2 | |||
1 | CREATE TABLE `regions` ( | 3 | CREATE TABLE `regions` ( |
2 | `uuid` varchar(36) NOT NULL, | 4 | `uuid` varchar(36) NOT NULL, |
3 | `regionHandle` bigint(20) unsigned NOT NULL, | 5 | `regionHandle` bigint(20) unsigned NOT NULL, |
@@ -30,3 +32,58 @@ CREATE TABLE `regions` ( | |||
30 | KEY `regionHandle` (`regionHandle`), | 32 | KEY `regionHandle` (`regionHandle`), |
31 | KEY `overrideHandles` (`eastOverrideHandle`,`westOverrideHandle`,`southOverrideHandle`,`northOverrideHandle`) | 33 | KEY `overrideHandles` (`eastOverrideHandle`,`westOverrideHandle`,`southOverrideHandle`,`northOverrideHandle`) |
32 | ) ENGINE=InnoDB DEFAULT CHARSET=utf8 ROW_FORMAT=FIXED COMMENT='Rev. 3'; | 34 | ) ENGINE=InnoDB DEFAULT CHARSET=utf8 ROW_FORMAT=FIXED COMMENT='Rev. 3'; |
35 | |||
36 | :VERSION 2 | ||
37 | |||
38 | BEGIN; | ||
39 | |||
40 | ALTER TABLE regions add column access integer unsigned default 1; | ||
41 | |||
42 | COMMIT; | ||
43 | |||
44 | :VERSION 3 | ||
45 | |||
46 | BEGIN; | ||
47 | |||
48 | ALTER TABLE regions add column ScopeID char(36) not null default '00000000-0000-0000-0000-000000000000'; | ||
49 | |||
50 | create index ScopeID on regions(ScopeID); | ||
51 | |||
52 | COMMIT; | ||
53 | |||
54 | :VERSION 4 | ||
55 | |||
56 | BEGIN; | ||
57 | |||
58 | ALTER TABLE regions add column sizeX integer not null default 0; | ||
59 | ALTER TABLE regions add column sizeY integer not null default 0; | ||
60 | |||
61 | COMMIT; | ||
62 | |||
63 | :VERSION 5 | ||
64 | |||
65 | BEGIN; | ||
66 | |||
67 | ALTER TABLE `regions` ADD COLUMN `flags` integer NOT NULL DEFAULT 0; | ||
68 | CREATE INDEX flags ON regions(flags); | ||
69 | |||
70 | COMMIT; | ||
71 | |||
72 | :VERSION 6 | ||
73 | |||
74 | BEGIN; | ||
75 | |||
76 | ALTER TABLE `regions` ADD COLUMN `last_seen` integer NOT NULL DEFAULT 0; | ||
77 | |||
78 | COMMIT; | ||
79 | |||
80 | :VERSION 7 | ||
81 | |||
82 | BEGIN; | ||
83 | |||
84 | ALTER TABLE `regions` ADD COLUMN `PrincipalID` char(36) NOT NULL DEFAULT '00000000-0000-0000-0000-000000000000'; | ||
85 | ALTER TABLE `regions` ADD COLUMN `Token` varchar(255) NOT NULL; | ||
86 | |||
87 | COMMIT; | ||
88 | |||
89 | |||
diff --git a/OpenSim/Data/MySQL/Resources/001_GridUserStore.sql b/OpenSim/Data/MySQL/Resources/GridUserStore.migrations index ce4ab96..32b85ee 100644 --- a/OpenSim/Data/MySQL/Resources/001_GridUserStore.sql +++ b/OpenSim/Data/MySQL/Resources/GridUserStore.migrations | |||
@@ -1,3 +1,5 @@ | |||
1 | :VERSION 1 # -------------------------- | ||
2 | |||
1 | BEGIN; | 3 | BEGIN; |
2 | 4 | ||
3 | CREATE TABLE `GridUser` ( | 5 | CREATE TABLE `GridUser` ( |
diff --git a/OpenSim/Data/MySQL/Resources/InventoryStore.migrations b/OpenSim/Data/MySQL/Resources/InventoryStore.migrations new file mode 100644 index 0000000..8c5864e --- /dev/null +++ b/OpenSim/Data/MySQL/Resources/InventoryStore.migrations | |||
@@ -0,0 +1,93 @@ | |||
1 | :VERSION 1 # ------------ | ||
2 | BEGIN; | ||
3 | |||
4 | CREATE TABLE `inventoryfolders` ( | ||
5 | `folderID` varchar(36) NOT NULL default '', | ||
6 | `agentID` varchar(36) default NULL, | ||
7 | `parentFolderID` varchar(36) default NULL, | ||
8 | `folderName` varchar(64) default NULL, | ||
9 | `type` smallint NOT NULL default 0, | ||
10 | `version` int NOT NULL default 0, | ||
11 | PRIMARY KEY (`folderID`), | ||
12 | KEY `owner` (`agentID`), | ||
13 | KEY `parent` (`parentFolderID`) | ||
14 | ) ENGINE=InnoDB DEFAULT CHARSET=utf8; | ||
15 | |||
16 | CREATE TABLE `inventoryitems` ( | ||
17 | `inventoryID` varchar(36) NOT NULL default '', | ||
18 | `assetID` varchar(36) default NULL, | ||
19 | `assetType` int(11) default NULL, | ||
20 | `parentFolderID` varchar(36) default NULL, | ||
21 | `avatarID` varchar(36) default NULL, | ||
22 | `inventoryName` varchar(64) default NULL, | ||
23 | `inventoryDescription` varchar(128) default NULL, | ||
24 | `inventoryNextPermissions` int(10) unsigned default NULL, | ||
25 | `inventoryCurrentPermissions` int(10) unsigned default NULL, | ||
26 | `invType` int(11) default NULL, | ||
27 | `creatorID` varchar(36) default NULL, | ||
28 | `inventoryBasePermissions` int(10) unsigned NOT NULL default 0, | ||
29 | `inventoryEveryOnePermissions` int(10) unsigned NOT NULL default 0, | ||
30 | `salePrice` int(11) NOT NULL default 0, | ||
31 | `saleType` tinyint(4) NOT NULL default 0, | ||
32 | `creationDate` int(11) NOT NULL default 0, | ||
33 | `groupID` varchar(36) NOT NULL default '00000000-0000-0000-0000-000000000000', | ||
34 | `groupOwned` tinyint(4) NOT NULL default 0, | ||
35 | `flags` int(11) unsigned NOT NULL default 0, | ||
36 | PRIMARY KEY (`inventoryID`), | ||
37 | KEY `owner` (`avatarID`), | ||
38 | KEY `folder` (`parentFolderID`) | ||
39 | ) ENGINE=InnoDB DEFAULT CHARSET=utf8; | ||
40 | |||
41 | COMMIT; | ||
42 | |||
43 | :VERSION 2 # ------------ | ||
44 | |||
45 | BEGIN; | ||
46 | |||
47 | ALTER TABLE inventoryfolders change folderID folderIDold varchar(36); | ||
48 | ALTER TABLE inventoryfolders change agentID agentIDold varchar(36); | ||
49 | ALTER TABLE inventoryfolders change parentFolderID parentFolderIDold varchar(36); | ||
50 | ALTER TABLE inventoryfolders add folderID char(36) not null default '00000000-0000-0000-0000-000000000000'; | ||
51 | ALTER TABLE inventoryfolders add agentID char(36) default NULL; | ||
52 | ALTER TABLE inventoryfolders add parentFolderID char(36) default NULL; | ||
53 | UPDATE inventoryfolders set folderID = folderIDold, agentID = agentIDold, parentFolderID = parentFolderIDold; | ||
54 | ALTER TABLE inventoryfolders drop folderIDold; | ||
55 | ALTER TABLE inventoryfolders drop agentIDold; | ||
56 | ALTER TABLE inventoryfolders drop parentFolderIDold; | ||
57 | ALTER TABLE inventoryfolders add constraint primary key(folderID); | ||
58 | ALTER TABLE inventoryfolders add index inventoryfolders_agentid(agentID); | ||
59 | ALTER TABLE inventoryfolders add index inventoryfolders_parentFolderid(parentFolderID); | ||
60 | |||
61 | ALTER TABLE inventoryitems change inventoryID inventoryIDold varchar(36); | ||
62 | ALTER TABLE inventoryitems change avatarID avatarIDold varchar(36); | ||
63 | ALTER TABLE inventoryitems change parentFolderID parentFolderIDold varchar(36); | ||
64 | ALTER TABLE inventoryitems add inventoryID char(36) not null default '00000000-0000-0000-0000-000000000000'; | ||
65 | ALTER TABLE inventoryitems add avatarID char(36) default NULL; | ||
66 | ALTER TABLE inventoryitems add parentFolderID char(36) default NULL; | ||
67 | UPDATE inventoryitems set inventoryID = inventoryIDold, avatarID = avatarIDold, parentFolderID = parentFolderIDold; | ||
68 | ALTER TABLE inventoryitems drop inventoryIDold; | ||
69 | ALTER TABLE inventoryitems drop avatarIDold; | ||
70 | ALTER TABLE inventoryitems drop parentFolderIDold; | ||
71 | ALTER TABLE inventoryitems add constraint primary key(inventoryID); | ||
72 | ALTER TABLE inventoryitems add index inventoryitems_avatarid(avatarID); | ||
73 | ALTER TABLE inventoryitems add index inventoryitems_parentFolderid(parentFolderID); | ||
74 | |||
75 | COMMIT; | ||
76 | |||
77 | :VERSION 3 # ------------ | ||
78 | |||
79 | BEGIN; | ||
80 | |||
81 | alter table inventoryitems add column inventoryGroupPermissions integer unsigned not null default 0; | ||
82 | |||
83 | COMMIT; | ||
84 | |||
85 | :VERSION 4 # ------------ | ||
86 | |||
87 | BEGIN; | ||
88 | |||
89 | update inventoryitems set creatorID = '00000000-0000-0000-0000-000000000000' where creatorID is NULL; | ||
90 | update inventoryitems set creatorID = '00000000-0000-0000-0000-000000000000' where creatorID = ''; | ||
91 | alter table inventoryitems modify column creatorID varchar(36) not NULL default '00000000-0000-0000-0000-000000000000'; | ||
92 | |||
93 | COMMIT; | ||
diff --git a/OpenSim/Data/MySQL/Resources/001_LogStore.sql b/OpenSim/Data/MySQL/Resources/LogStore.migrations index b4c29fb..9ac26ac 100644 --- a/OpenSim/Data/MySQL/Resources/001_LogStore.sql +++ b/OpenSim/Data/MySQL/Resources/LogStore.migrations | |||
@@ -1,3 +1,6 @@ | |||
1 | | ||
2 | :VERSION 1 | ||
3 | |||
1 | CREATE TABLE `logs` ( | 4 | CREATE TABLE `logs` ( |
2 | `logID` int(10) unsigned NOT NULL auto_increment, | 5 | `logID` int(10) unsigned NOT NULL auto_increment, |
3 | `target` varchar(36) default NULL, | 6 | `target` varchar(36) default NULL, |
diff --git a/OpenSim/Data/MySQL/Resources/001_Presence.sql b/OpenSim/Data/MySQL/Resources/Presence.migrations index 84fa057..91f7de5 100644 --- a/OpenSim/Data/MySQL/Resources/001_Presence.sql +++ b/OpenSim/Data/MySQL/Resources/Presence.migrations | |||
@@ -1,8 +1,10 @@ | |||
1 | :VERSION 1 # -------------------------- | ||
2 | |||
1 | BEGIN; | 3 | BEGIN; |
2 | 4 | ||
3 | CREATE TABLE `Presence` ( | 5 | CREATE TABLE `Presence` ( |
4 | `UserID` VARCHAR(255) NOT NULL, | 6 | `UserID` VARCHAR(255) NOT NULL, |
5 | `RegionID` CHAR(36) NOT NULL, | 7 | `RegionID` CHAR(36) NOT NULL DEFAULT '00000000-0000-0000-0000-000000000000', |
6 | `SessionID` CHAR(36) NOT NULL DEFAULT '00000000-0000-0000-0000-000000000000', | 8 | `SessionID` CHAR(36) NOT NULL DEFAULT '00000000-0000-0000-0000-000000000000', |
7 | `SecureSessionID` CHAR(36) NOT NULL DEFAULT '00000000-0000-0000-0000-000000000000' | 9 | `SecureSessionID` CHAR(36) NOT NULL DEFAULT '00000000-0000-0000-0000-000000000000' |
8 | ) ENGINE=InnoDB; | 10 | ) ENGINE=InnoDB; |
diff --git a/OpenSim/Data/MySQL/Resources/RegionStore.migrations b/OpenSim/Data/MySQL/Resources/RegionStore.migrations new file mode 100644 index 0000000..ba898bb --- /dev/null +++ b/OpenSim/Data/MySQL/Resources/RegionStore.migrations | |||
@@ -0,0 +1,876 @@ | |||
1 | | ||
2 | :VERSION 1 #--------------------- | ||
3 | |||
4 | BEGIN; | ||
5 | |||
6 | CREATE TABLE `prims` ( | ||
7 | `UUID` varchar(255) NOT NULL, | ||
8 | `RegionUUID` varchar(255) default NULL, | ||
9 | `ParentID` int(11) default NULL, | ||
10 | `CreationDate` int(11) default NULL, | ||
11 | `Name` varchar(255) default NULL, | ||
12 | `SceneGroupID` varchar(255) default NULL, | ||
13 | `Text` varchar(255) default NULL, | ||
14 | `Description` varchar(255) default NULL, | ||
15 | `SitName` varchar(255) default NULL, | ||
16 | `TouchName` varchar(255) default NULL, | ||
17 | `ObjectFlags` int(11) default NULL, | ||
18 | `CreatorID` varchar(255) default NULL, | ||
19 | `OwnerID` varchar(255) default NULL, | ||
20 | `GroupID` varchar(255) default NULL, | ||
21 | `LastOwnerID` varchar(255) default NULL, | ||
22 | `OwnerMask` int(11) default NULL, | ||
23 | `NextOwnerMask` int(11) default NULL, | ||
24 | `GroupMask` int(11) default NULL, | ||
25 | `EveryoneMask` int(11) default NULL, | ||
26 | `BaseMask` int(11) default NULL, | ||
27 | `PositionX` float default NULL, | ||
28 | `PositionY` float default NULL, | ||
29 | `PositionZ` float default NULL, | ||
30 | `GroupPositionX` float default NULL, | ||
31 | `GroupPositionY` float default NULL, | ||
32 | `GroupPositionZ` float default NULL, | ||
33 | `VelocityX` float default NULL, | ||
34 | `VelocityY` float default NULL, | ||
35 | `VelocityZ` float default NULL, | ||
36 | `AngularVelocityX` float default NULL, | ||
37 | `AngularVelocityY` float default NULL, | ||
38 | `AngularVelocityZ` float default NULL, | ||
39 | `AccelerationX` float default NULL, | ||
40 | `AccelerationY` float default NULL, | ||
41 | `AccelerationZ` float default NULL, | ||
42 | `RotationX` float default NULL, | ||
43 | `RotationY` float default NULL, | ||
44 | `RotationZ` float default NULL, | ||
45 | `RotationW` float default NULL, | ||
46 | `SitTargetOffsetX` float default NULL, | ||
47 | `SitTargetOffsetY` float default NULL, | ||
48 | `SitTargetOffsetZ` float default NULL, | ||
49 | `SitTargetOrientW` float default NULL, | ||
50 | `SitTargetOrientX` float default NULL, | ||
51 | `SitTargetOrientY` float default NULL, | ||
52 | `SitTargetOrientZ` float default NULL, | ||
53 | PRIMARY KEY (`UUID`) | ||
54 | ) ENGINE=MyISAM DEFAULT CHARSET=latin1; | ||
55 | |||
56 | CREATE TABLE `primshapes` ( | ||
57 | `UUID` varchar(255) NOT NULL, | ||
58 | `Shape` int(11) default NULL, | ||
59 | `ScaleX` float default NULL, | ||
60 | `ScaleY` float default NULL, | ||
61 | `ScaleZ` float default NULL, | ||
62 | `PCode` int(11) default NULL, | ||
63 | `PathBegin` int(11) default NULL, | ||
64 | `PathEnd` int(11) default NULL, | ||
65 | `PathScaleX` int(11) default NULL, | ||
66 | `PathScaleY` int(11) default NULL, | ||
67 | `PathShearX` int(11) default NULL, | ||
68 | `PathShearY` int(11) default NULL, | ||
69 | `PathSkew` int(11) default NULL, | ||
70 | `PathCurve` int(11) default NULL, | ||
71 | `PathRadiusOffset` int(11) default NULL, | ||
72 | `PathRevolutions` int(11) default NULL, | ||
73 | `PathTaperX` int(11) default NULL, | ||
74 | `PathTaperY` int(11) default NULL, | ||
75 | `PathTwist` int(11) default NULL, | ||
76 | `PathTwistBegin` int(11) default NULL, | ||
77 | `ProfileBegin` int(11) default NULL, | ||
78 | `ProfileEnd` int(11) default NULL, | ||
79 | `ProfileCurve` int(11) default NULL, | ||
80 | `ProfileHollow` int(11) default NULL, | ||
81 | `State` int(11) default NULL, | ||
82 | `Texture` longblob, | ||
83 | `ExtraParams` longblob, | ||
84 | PRIMARY KEY (`UUID`) | ||
85 | ) ENGINE=MyISAM DEFAULT CHARSET=latin1; | ||
86 | |||
87 | CREATE TABLE `primitems` ( | ||
88 | `itemID` varchar(255) NOT NULL, | ||
89 | `primID` varchar(255) default NULL, | ||
90 | `assetID` varchar(255) default NULL, | ||
91 | `parentFolderID` varchar(255) default NULL, | ||
92 | `invType` int(11) default NULL, | ||
93 | `assetType` int(11) default NULL, | ||
94 | `name` varchar(255) default NULL, | ||
95 | `description` varchar(255) default NULL, | ||
96 | `creationDate` bigint(20) default NULL, | ||
97 | `creatorID` varchar(255) default NULL, | ||
98 | `ownerID` varchar(255) default NULL, | ||
99 | `lastOwnerID` varchar(255) default NULL, | ||
100 | `groupID` varchar(255) default NULL, | ||
101 | `nextPermissions` int(11) default NULL, | ||
102 | `currentPermissions` int(11) default NULL, | ||
103 | `basePermissions` int(11) default NULL, | ||
104 | `everyonePermissions` int(11) default NULL, | ||
105 | `groupPermissions` int(11) default NULL, | ||
106 | PRIMARY KEY (`itemID`) | ||
107 | ) ENGINE=MyISAM DEFAULT CHARSET=latin1; | ||
108 | |||
109 | CREATE TABLE `terrain` ( | ||
110 | `RegionUUID` varchar(255) default NULL, | ||
111 | `Revision` int(11) default NULL, | ||
112 | `Heightfield` longblob | ||
113 | ) ENGINE=MyISAM DEFAULT CHARSET=latin1; | ||
114 | |||
115 | CREATE TABLE `land` ( | ||
116 | `UUID` varchar(255) NOT NULL, | ||
117 | `RegionUUID` varchar(255) default NULL, | ||
118 | `LocalLandID` int(11) default NULL, | ||
119 | `Bitmap` longblob, | ||
120 | `Name` varchar(255) default NULL, | ||
121 | `Description` varchar(255) default NULL, | ||
122 | `OwnerUUID` varchar(255) default NULL, | ||
123 | `IsGroupOwned` int(11) default NULL, | ||
124 | `Area` int(11) default NULL, | ||
125 | `AuctionID` int(11) default NULL, | ||
126 | `Category` int(11) default NULL, | ||
127 | `ClaimDate` int(11) default NULL, | ||
128 | `ClaimPrice` int(11) default NULL, | ||
129 | `GroupUUID` varchar(255) default NULL, | ||
130 | `SalePrice` int(11) default NULL, | ||
131 | `LandStatus` int(11) default NULL, | ||
132 | `LandFlags` int(11) default NULL, | ||
133 | `LandingType` int(11) default NULL, | ||
134 | `MediaAutoScale` int(11) default NULL, | ||
135 | `MediaTextureUUID` varchar(255) default NULL, | ||
136 | `MediaURL` varchar(255) default NULL, | ||
137 | `MusicURL` varchar(255) default NULL, | ||
138 | `PassHours` float default NULL, | ||
139 | `PassPrice` int(11) default NULL, | ||
140 | `SnapshotUUID` varchar(255) default NULL, | ||
141 | `UserLocationX` float default NULL, | ||
142 | `UserLocationY` float default NULL, | ||
143 | `UserLocationZ` float default NULL, | ||
144 | `UserLookAtX` float default NULL, | ||
145 | `UserLookAtY` float default NULL, | ||
146 | `UserLookAtZ` float default NULL, | ||
147 | `AuthbuyerID` varchar(36) NOT NULL default '00000000-0000-0000-0000-000000000000', | ||
148 | PRIMARY KEY (`UUID`) | ||
149 | ) ENGINE=InnoDB DEFAULT CHARSET=utf8; | ||
150 | |||
151 | CREATE TABLE `landaccesslist` ( | ||
152 | `LandUUID` varchar(255) default NULL, | ||
153 | `AccessUUID` varchar(255) default NULL, | ||
154 | `Flags` int(11) default NULL | ||
155 | ) ENGINE=MyISAM DEFAULT CHARSET=latin1; | ||
156 | |||
157 | COMMIT; | ||
158 | |||
159 | :VERSION 2 #--------------------- | ||
160 | |||
161 | BEGIN; | ||
162 | |||
163 | CREATE index prims_regionuuid on prims(RegionUUID); | ||
164 | CREATE index primitems_primid on primitems(primID); | ||
165 | |||
166 | COMMIT; | ||
167 | |||
168 | :VERSION 3 #--------------------- | ||
169 | |||
170 | BEGIN; | ||
171 | CREATE TABLE regionban (regionUUID VARCHAR(36) NOT NULL, bannedUUID VARCHAR(36) NOT NULL, bannedIp VARCHAR(16) NOT NULL, bannedIpHostMask VARCHAR(16) NOT NULL) ENGINE=INNODB DEFAULT CHARSET=utf8 COMMENT='Rev. 1'; | ||
172 | COMMIT; | ||
173 | |||
174 | :VERSION 4 #--------------------- | ||
175 | |||
176 | BEGIN; | ||
177 | |||
178 | ALTER TABLE primitems add flags integer not null default 0; | ||
179 | |||
180 | COMMIT; | ||
181 | |||
182 | :VERSION 5 #--------------------- | ||
183 | BEGIN; | ||
184 | |||
185 | create table regionsettings ( | ||
186 | regionUUID char(36) not null, | ||
187 | block_terraform integer not null, | ||
188 | block_fly integer not null, | ||
189 | allow_damage integer not null, | ||
190 | restrict_pushing integer not null, | ||
191 | allow_land_resell integer not null, | ||
192 | allow_land_join_divide integer not null, | ||
193 | block_show_in_search integer not null, | ||
194 | agent_limit integer not null, | ||
195 | object_bonus float not null, | ||
196 | maturity integer not null, | ||
197 | disable_scripts integer not null, | ||
198 | disable_collisions integer not null, | ||
199 | disable_physics integer not null, | ||
200 | terrain_texture_1 char(36) not null, | ||
201 | terrain_texture_2 char(36) not null, | ||
202 | terrain_texture_3 char(36) not null, | ||
203 | terrain_texture_4 char(36) not null, | ||
204 | elevation_1_nw float not null, | ||
205 | elevation_2_nw float not null, | ||
206 | elevation_1_ne float not null, | ||
207 | elevation_2_ne float not null, | ||
208 | elevation_1_se float not null, | ||
209 | elevation_2_se float not null, | ||
210 | elevation_1_sw float not null, | ||
211 | elevation_2_sw float not null, | ||
212 | water_height float not null, | ||
213 | terrain_raise_limit float not null, | ||
214 | terrain_lower_limit float not null, | ||
215 | use_estate_sun integer not null, | ||
216 | fixed_sun integer not null, | ||
217 | sun_position float not null, | ||
218 | covenant char(36), | ||
219 | primary key(regionUUID) | ||
220 | ); | ||
221 | |||
222 | COMMIT; | ||
223 | |||
224 | |||
225 | :VERSION 6 #--------------------- | ||
226 | |||
227 | BEGIN; | ||
228 | |||
229 | alter table landaccesslist ENGINE = InnoDB; | ||
230 | alter table migrations ENGINE = InnoDB; | ||
231 | alter table primitems ENGINE = InnoDB; | ||
232 | alter table prims ENGINE = InnoDB; | ||
233 | alter table primshapes ENGINE = InnoDB; | ||
234 | alter table regionsettings ENGINE = InnoDB; | ||
235 | alter table terrain ENGINE = InnoDB; | ||
236 | |||
237 | COMMIT; | ||
238 | |||
239 | :VERSION 7 #--------------------- | ||
240 | |||
241 | BEGIN; | ||
242 | |||
243 | ALTER TABLE prims change UUID UUIDold varchar(255); | ||
244 | ALTER TABLE prims change RegionUUID RegionUUIDold varchar(255); | ||
245 | ALTER TABLE prims change CreatorID CreatorIDold varchar(255); | ||
246 | ALTER TABLE prims change OwnerID OwnerIDold varchar(255); | ||
247 | ALTER TABLE prims change GroupID GroupIDold varchar(255); | ||
248 | ALTER TABLE prims change LastOwnerID LastOwnerIDold varchar(255); | ||
249 | ALTER TABLE prims add UUID char(36); | ||
250 | ALTER TABLE prims add RegionUUID char(36); | ||
251 | ALTER TABLE prims add CreatorID char(36); | ||
252 | ALTER TABLE prims add OwnerID char(36); | ||
253 | ALTER TABLE prims add GroupID char(36); | ||
254 | ALTER TABLE prims add LastOwnerID char(36); | ||
255 | UPDATE prims set UUID = UUIDold, RegionUUID = RegionUUIDold, CreatorID = CreatorIDold, OwnerID = OwnerIDold, GroupID = GroupIDold, LastOwnerID = LastOwnerIDold; | ||
256 | ALTER TABLE prims drop UUIDold; | ||
257 | ALTER TABLE prims drop RegionUUIDold; | ||
258 | ALTER TABLE prims drop CreatorIDold; | ||
259 | ALTER TABLE prims drop OwnerIDold; | ||
260 | ALTER TABLE prims drop GroupIDold; | ||
261 | ALTER TABLE prims drop LastOwnerIDold; | ||
262 | ALTER TABLE prims add constraint primary key(UUID); | ||
263 | ALTER TABLE prims add index prims_regionuuid(RegionUUID); | ||
264 | |||
265 | COMMIT; | ||
266 | |||
267 | :VERSION 8 #--------------------- | ||
268 | |||
269 | BEGIN; | ||
270 | |||
271 | ALTER TABLE primshapes change UUID UUIDold varchar(255); | ||
272 | ALTER TABLE primshapes add UUID char(36); | ||
273 | UPDATE primshapes set UUID = UUIDold; | ||
274 | ALTER TABLE primshapes drop UUIDold; | ||
275 | ALTER TABLE primshapes add constraint primary key(UUID); | ||
276 | |||
277 | COMMIT; | ||
278 | |||
279 | :VERSION 9 #--------------------- | ||
280 | |||
281 | BEGIN; | ||
282 | |||
283 | ALTER TABLE primitems change itemID itemIDold varchar(255); | ||
284 | ALTER TABLE primitems change primID primIDold varchar(255); | ||
285 | ALTER TABLE primitems change assetID assetIDold varchar(255); | ||
286 | ALTER TABLE primitems change parentFolderID parentFolderIDold varchar(255); | ||
287 | ALTER TABLE primitems change creatorID creatorIDold varchar(255); | ||
288 | ALTER TABLE primitems change ownerID ownerIDold varchar(255); | ||
289 | ALTER TABLE primitems change groupID groupIDold varchar(255); | ||
290 | ALTER TABLE primitems change lastOwnerID lastOwnerIDold varchar(255); | ||
291 | ALTER TABLE primitems add itemID char(36); | ||
292 | ALTER TABLE primitems add primID char(36); | ||
293 | ALTER TABLE primitems add assetID char(36); | ||
294 | ALTER TABLE primitems add parentFolderID char(36); | ||
295 | ALTER TABLE primitems add creatorID char(36); | ||
296 | ALTER TABLE primitems add ownerID char(36); | ||
297 | ALTER TABLE primitems add groupID char(36); | ||
298 | ALTER TABLE primitems add lastOwnerID char(36); | ||
299 | UPDATE primitems set itemID = itemIDold, primID = primIDold, assetID = assetIDold, parentFolderID = parentFolderIDold, creatorID = creatorIDold, ownerID = ownerIDold, groupID = groupIDold, lastOwnerID = lastOwnerIDold; | ||
300 | ALTER TABLE primitems drop itemIDold; | ||
301 | ALTER TABLE primitems drop primIDold; | ||
302 | ALTER TABLE primitems drop assetIDold; | ||
303 | ALTER TABLE primitems drop parentFolderIDold; | ||
304 | ALTER TABLE primitems drop creatorIDold; | ||
305 | ALTER TABLE primitems drop ownerIDold; | ||
306 | ALTER TABLE primitems drop groupIDold; | ||
307 | ALTER TABLE primitems drop lastOwnerIDold; | ||
308 | ALTER TABLE primitems add constraint primary key(itemID); | ||
309 | ALTER TABLE primitems add index primitems_primid(primID); | ||
310 | |||
311 | COMMIT; | ||
312 | |||
313 | :VERSION 10 #--------------------- | ||
314 | |||
315 | # 1 "010_RegionStore.sql" | ||
316 | # 1 "<built-in>" | ||
317 | # 1 "<command line>" | ||
318 | # 1 "010_RegionStore.sql" | ||
319 | BEGIN; | ||
320 | |||
321 | DELETE FROM regionsettings; | ||
322 | |||
323 | COMMIT; | ||
324 | |||
325 | |||
326 | :VERSION 11 #--------------------- | ||
327 | |||
328 | BEGIN; | ||
329 | |||
330 | ALTER TABLE prims change SceneGroupID SceneGroupIDold varchar(255); | ||
331 | ALTER TABLE prims add SceneGroupID char(36); | ||
332 | UPDATE prims set SceneGroupID = SceneGroupIDold; | ||
333 | ALTER TABLE prims drop SceneGroupIDold; | ||
334 | ALTER TABLE prims add index prims_scenegroupid(SceneGroupID); | ||
335 | |||
336 | COMMIT; | ||
337 | |||
338 | :VERSION 12 #--------------------- | ||
339 | |||
340 | BEGIN; | ||
341 | |||
342 | ALTER TABLE prims add index prims_parentid(ParentID); | ||
343 | |||
344 | COMMIT; | ||
345 | |||
346 | :VERSION 13 #--------------------- | ||
347 | begin; | ||
348 | |||
349 | drop table regionsettings; | ||
350 | |||
351 | CREATE TABLE `regionsettings` ( | ||
352 | `regionUUID` char(36) NOT NULL, | ||
353 | `block_terraform` int(11) NOT NULL, | ||
354 | `block_fly` int(11) NOT NULL, | ||
355 | `allow_damage` int(11) NOT NULL, | ||
356 | `restrict_pushing` int(11) NOT NULL, | ||
357 | `allow_land_resell` int(11) NOT NULL, | ||
358 | `allow_land_join_divide` int(11) NOT NULL, | ||
359 | `block_show_in_search` int(11) NOT NULL, | ||
360 | `agent_limit` int(11) NOT NULL, | ||
361 | `object_bonus` float NOT NULL, | ||
362 | `maturity` int(11) NOT NULL, | ||
363 | `disable_scripts` int(11) NOT NULL, | ||
364 | `disable_collisions` int(11) NOT NULL, | ||
365 | `disable_physics` int(11) NOT NULL, | ||
366 | `terrain_texture_1` char(36) NOT NULL, | ||
367 | `terrain_texture_2` char(36) NOT NULL, | ||
368 | `terrain_texture_3` char(36) NOT NULL, | ||
369 | `terrain_texture_4` char(36) NOT NULL, | ||
370 | `elevation_1_nw` float NOT NULL, | ||
371 | `elevation_2_nw` float NOT NULL, | ||
372 | `elevation_1_ne` float NOT NULL, | ||
373 | `elevation_2_ne` float NOT NULL, | ||
374 | `elevation_1_se` float NOT NULL, | ||
375 | `elevation_2_se` float NOT NULL, | ||
376 | `elevation_1_sw` float NOT NULL, | ||
377 | `elevation_2_sw` float NOT NULL, | ||
378 | `water_height` float NOT NULL, | ||
379 | `terrain_raise_limit` float NOT NULL, | ||
380 | `terrain_lower_limit` float NOT NULL, | ||
381 | `use_estate_sun` int(11) NOT NULL, | ||
382 | `fixed_sun` int(11) NOT NULL, | ||
383 | `sun_position` float NOT NULL, | ||
384 | `covenant` char(36) default NULL, | ||
385 | `Sandbox` tinyint(4) NOT NULL, | ||
386 | PRIMARY KEY (`regionUUID`) | ||
387 | ) ENGINE=InnoDB; | ||
388 | |||
389 | CREATE TABLE `estate_managers` ( | ||
390 | `EstateID` int(10) unsigned NOT NULL, | ||
391 | `uuid` char(36) NOT NULL, | ||
392 | KEY `EstateID` (`EstateID`) | ||
393 | ) ENGINE=InnoDB; | ||
394 | |||
395 | CREATE TABLE `estate_groups` ( | ||
396 | `EstateID` int(10) unsigned NOT NULL, | ||
397 | `uuid` char(36) NOT NULL, | ||
398 | KEY `EstateID` (`EstateID`) | ||
399 | ) ENGINE=InnoDB; | ||
400 | |||
401 | CREATE TABLE `estate_users` ( | ||
402 | `EstateID` int(10) unsigned NOT NULL, | ||
403 | `uuid` char(36) NOT NULL, | ||
404 | KEY `EstateID` (`EstateID`) | ||
405 | ) ENGINE=InnoDB; | ||
406 | |||
407 | CREATE TABLE `estateban` ( | ||
408 | `EstateID` int(10) unsigned NOT NULL, | ||
409 | `bannedUUID` varchar(36) NOT NULL, | ||
410 | `bannedIp` varchar(16) NOT NULL, | ||
411 | `bannedIpHostMask` varchar(16) NOT NULL, | ||
412 | `bannedNameMask` varchar(64) default NULL, | ||
413 | KEY `estateban_EstateID` (`EstateID`) | ||
414 | ) ENGINE=InnoDB; | ||
415 | |||
416 | CREATE TABLE `estate_settings` ( | ||
417 | `EstateID` int(10) unsigned NOT NULL auto_increment, | ||
418 | `EstateName` varchar(64) default NULL, | ||
419 | `AbuseEmailToEstateOwner` tinyint(4) NOT NULL, | ||
420 | `DenyAnonymous` tinyint(4) NOT NULL, | ||
421 | `ResetHomeOnTeleport` tinyint(4) NOT NULL, | ||
422 | `FixedSun` tinyint(4) NOT NULL, | ||
423 | `DenyTransacted` tinyint(4) NOT NULL, | ||
424 | `BlockDwell` tinyint(4) NOT NULL, | ||
425 | `DenyIdentified` tinyint(4) NOT NULL, | ||
426 | `AllowVoice` tinyint(4) NOT NULL, | ||
427 | `UseGlobalTime` tinyint(4) NOT NULL, | ||
428 | `PricePerMeter` int(11) NOT NULL, | ||
429 | `TaxFree` tinyint(4) NOT NULL, | ||
430 | `AllowDirectTeleport` tinyint(4) NOT NULL, | ||
431 | `RedirectGridX` int(11) NOT NULL, | ||
432 | `RedirectGridY` int(11) NOT NULL, | ||
433 | `ParentEstateID` int(10) unsigned NOT NULL, | ||
434 | `SunPosition` double NOT NULL, | ||
435 | `EstateSkipScripts` tinyint(4) NOT NULL, | ||
436 | `BillableFactor` float NOT NULL, | ||
437 | `PublicAccess` tinyint(4) NOT NULL, | ||
438 | PRIMARY KEY (`EstateID`) | ||
439 | ) ENGINE=InnoDB AUTO_INCREMENT=100; | ||
440 | |||
441 | CREATE TABLE `estate_map` ( | ||
442 | `RegionID` char(36) NOT NULL default '00000000-0000-0000-0000-000000000000', | ||
443 | `EstateID` int(11) NOT NULL, | ||
444 | PRIMARY KEY (`RegionID`), | ||
445 | KEY `EstateID` (`EstateID`) | ||
446 | ) ENGINE=InnoDB; | ||
447 | |||
448 | commit; | ||
449 | |||
450 | :VERSION 14 #--------------------- | ||
451 | |||
452 | begin; | ||
453 | |||
454 | alter table estate_settings add column AbuseEmail varchar(255) not null; | ||
455 | |||
456 | alter table estate_settings add column EstateOwner varchar(36) not null; | ||
457 | |||
458 | commit; | ||
459 | |||
460 | |||
461 | :VERSION 15 #--------------------- | ||
462 | |||
463 | begin; | ||
464 | |||
465 | alter table estate_settings add column DenyMinors tinyint not null; | ||
466 | |||
467 | commit; | ||
468 | |||
469 | :VERSION 16 #--------------------- | ||
470 | |||
471 | BEGIN; | ||
472 | |||
473 | ALTER TABLE prims ADD COLUMN PayPrice integer not null default 0; | ||
474 | ALTER TABLE prims ADD COLUMN PayButton1 integer not null default 0; | ||
475 | ALTER TABLE prims ADD COLUMN PayButton2 integer not null default 0; | ||
476 | ALTER TABLE prims ADD COLUMN PayButton3 integer not null default 0; | ||
477 | ALTER TABLE prims ADD COLUMN PayButton4 integer not null default 0; | ||
478 | ALTER TABLE prims ADD COLUMN LoopedSound char(36) not null default '00000000-0000-0000-0000-000000000000'; | ||
479 | ALTER TABLE prims ADD COLUMN LoopedSoundGain float not null default 0.0; | ||
480 | ALTER TABLE prims ADD COLUMN TextureAnimation blob; | ||
481 | ALTER TABLE prims ADD COLUMN OmegaX float not null default 0.0; | ||
482 | ALTER TABLE prims ADD COLUMN OmegaY float not null default 0.0; | ||
483 | ALTER TABLE prims ADD COLUMN OmegaZ float not null default 0.0; | ||
484 | ALTER TABLE prims ADD COLUMN CameraEyeOffsetX float not null default 0.0; | ||
485 | ALTER TABLE prims ADD COLUMN CameraEyeOffsetY float not null default 0.0; | ||
486 | ALTER TABLE prims ADD COLUMN CameraEyeOffsetZ float not null default 0.0; | ||
487 | ALTER TABLE prims ADD COLUMN CameraAtOffsetX float not null default 0.0; | ||
488 | ALTER TABLE prims ADD COLUMN CameraAtOffsetY float not null default 0.0; | ||
489 | ALTER TABLE prims ADD COLUMN CameraAtOffsetZ float not null default 0.0; | ||
490 | ALTER TABLE prims ADD COLUMN ForceMouselook tinyint not null default 0; | ||
491 | ALTER TABLE prims ADD COLUMN ScriptAccessPin integer not null default 0; | ||
492 | ALTER TABLE prims ADD COLUMN AllowedDrop tinyint not null default 0; | ||
493 | ALTER TABLE prims ADD COLUMN DieAtEdge tinyint not null default 0; | ||
494 | ALTER TABLE prims ADD COLUMN SalePrice integer not null default 10; | ||
495 | ALTER TABLE prims ADD COLUMN SaleType tinyint not null default 0; | ||
496 | |||
497 | COMMIT; | ||
498 | |||
499 | |||
500 | :VERSION 17 #--------------------- | ||
501 | |||
502 | BEGIN; | ||
503 | |||
504 | ALTER TABLE prims ADD COLUMN ColorR integer not null default 0; | ||
505 | ALTER TABLE prims ADD COLUMN ColorG integer not null default 0; | ||
506 | ALTER TABLE prims ADD COLUMN ColorB integer not null default 0; | ||
507 | ALTER TABLE prims ADD COLUMN ColorA integer not null default 0; | ||
508 | ALTER TABLE prims ADD COLUMN ParticleSystem blob; | ||
509 | |||
510 | COMMIT; | ||
511 | |||
512 | |||
513 | :VERSION 18 #--------------------- | ||
514 | |||
515 | begin; | ||
516 | |||
517 | ALTER TABLE prims ADD COLUMN ClickAction tinyint NOT NULL default 0; | ||
518 | |||
519 | commit; | ||
520 | |||
521 | :VERSION 19 #--------------------- | ||
522 | |||
523 | begin; | ||
524 | |||
525 | ALTER TABLE prims ADD COLUMN Material tinyint NOT NULL default 3; | ||
526 | |||
527 | commit; | ||
528 | |||
529 | |||
530 | :VERSION 20 #--------------------- | ||
531 | |||
532 | begin; | ||
533 | |||
534 | ALTER TABLE land ADD COLUMN OtherCleanTime integer NOT NULL default 0; | ||
535 | ALTER TABLE land ADD COLUMN Dwell integer NOT NULL default 0; | ||
536 | |||
537 | commit; | ||
538 | |||
539 | :VERSION 21 #--------------------- | ||
540 | |||
541 | begin; | ||
542 | |||
543 | ALTER TABLE regionsettings ADD COLUMN sunvectorx double NOT NULL default 0; | ||
544 | ALTER TABLE regionsettings ADD COLUMN sunvectory double NOT NULL default 0; | ||
545 | ALTER TABLE regionsettings ADD COLUMN sunvectorz double NOT NULL default 0; | ||
546 | |||
547 | commit; | ||
548 | |||
549 | |||
550 | :VERSION 22 #--------------------- | ||
551 | |||
552 | BEGIN; | ||
553 | |||
554 | ALTER TABLE prims ADD COLUMN CollisionSound char(36) not null default '00000000-0000-0000-0000-000000000000'; | ||
555 | ALTER TABLE prims ADD COLUMN CollisionSoundVolume float not null default 0.0; | ||
556 | |||
557 | COMMIT; | ||
558 | |||
559 | :VERSION 23 #--------------------- | ||
560 | |||
561 | BEGIN; | ||
562 | |||
563 | ALTER TABLE prims ADD COLUMN LinkNumber integer not null default 0; | ||
564 | |||
565 | COMMIT; | ||
566 | |||
567 | :VERSION 24 #--------------------- | ||
568 | |||
569 | BEGIN; | ||
570 | |||
571 | alter table regionsettings change column `object_bonus` `object_bonus` double NOT NULL; | ||
572 | alter table regionsettings change column `elevation_1_nw` `elevation_1_nw` double NOT NULL; | ||
573 | alter table regionsettings change column `elevation_2_nw` `elevation_2_nw` double NOT NULL; | ||
574 | alter table regionsettings change column `elevation_1_ne` `elevation_1_ne` double NOT NULL; | ||
575 | alter table regionsettings change column `elevation_2_ne` `elevation_2_ne` double NOT NULL; | ||
576 | alter table regionsettings change column `elevation_1_se` `elevation_1_se` double NOT NULL; | ||
577 | alter table regionsettings change column `elevation_2_se` `elevation_2_se` double NOT NULL; | ||
578 | alter table regionsettings change column `elevation_1_sw` `elevation_1_sw` double NOT NULL; | ||
579 | alter table regionsettings change column `elevation_2_sw` `elevation_2_sw` double NOT NULL; | ||
580 | alter table regionsettings change column `water_height` `water_height` double NOT NULL; | ||
581 | alter table regionsettings change column `terrain_raise_limit` `terrain_raise_limit` double NOT NULL; | ||
582 | alter table regionsettings change column `terrain_lower_limit` `terrain_lower_limit` double NOT NULL; | ||
583 | alter table regionsettings change column `sun_position` `sun_position` double NOT NULL; | ||
584 | |||
585 | COMMIT; | ||
586 | |||
587 | |||
588 | :VERSION 25 #--------------------- | ||
589 | |||
590 | BEGIN; | ||
591 | |||
592 | alter table prims change column `PositionX` `PositionX` double default NULL; | ||
593 | alter table prims change column `PositionY` `PositionY` double default NULL; | ||
594 | alter table prims change column `PositionZ` `PositionZ` double default NULL; | ||
595 | alter table prims change column `GroupPositionX` `GroupPositionX` double default NULL; | ||
596 | alter table prims change column `GroupPositionY` `GroupPositionY` double default NULL; | ||
597 | alter table prims change column `GroupPositionZ` `GroupPositionZ` double default NULL; | ||
598 | alter table prims change column `VelocityX` `VelocityX` double default NULL; | ||
599 | alter table prims change column `VelocityY` `VelocityY` double default NULL; | ||
600 | alter table prims change column `VelocityZ` `VelocityZ` double default NULL; | ||
601 | alter table prims change column `AngularVelocityX` `AngularVelocityX` double default NULL; | ||
602 | alter table prims change column `AngularVelocityY` `AngularVelocityY` double default NULL; | ||
603 | alter table prims change column `AngularVelocityZ` `AngularVelocityZ` double default NULL; | ||
604 | alter table prims change column `AccelerationX` `AccelerationX` double default NULL; | ||
605 | alter table prims change column `AccelerationY` `AccelerationY` double default NULL; | ||
606 | alter table prims change column `AccelerationZ` `AccelerationZ` double default NULL; | ||
607 | alter table prims change column `RotationX` `RotationX` double default NULL; | ||
608 | alter table prims change column `RotationY` `RotationY` double default NULL; | ||
609 | alter table prims change column `RotationZ` `RotationZ` double default NULL; | ||
610 | alter table prims change column `RotationW` `RotationW` double default NULL; | ||
611 | alter table prims change column `SitTargetOffsetX` `SitTargetOffsetX` double default NULL; | ||
612 | alter table prims change column `SitTargetOffsetY` `SitTargetOffsetY` double default NULL; | ||
613 | alter table prims change column `SitTargetOffsetZ` `SitTargetOffsetZ` double default NULL; | ||
614 | alter table prims change column `SitTargetOrientW` `SitTargetOrientW` double default NULL; | ||
615 | alter table prims change column `SitTargetOrientX` `SitTargetOrientX` double default NULL; | ||
616 | alter table prims change column `SitTargetOrientY` `SitTargetOrientY` double default NULL; | ||
617 | alter table prims change column `SitTargetOrientZ` `SitTargetOrientZ` double default NULL; | ||
618 | alter table prims change column `LoopedSoundGain` `LoopedSoundGain` double NOT NULL default '0'; | ||
619 | alter table prims change column `OmegaX` `OmegaX` double NOT NULL default '0'; | ||
620 | alter table prims change column `OmegaY` `OmegaY` double NOT NULL default '0'; | ||
621 | alter table prims change column `OmegaZ` `OmegaZ` double NOT NULL default '0'; | ||
622 | alter table prims change column `CameraEyeOffsetX` `CameraEyeOffsetX` double NOT NULL default '0'; | ||
623 | alter table prims change column `CameraEyeOffsetY` `CameraEyeOffsetY` double NOT NULL default '0'; | ||
624 | alter table prims change column `CameraEyeOffsetZ` `CameraEyeOffsetZ` double NOT NULL default '0'; | ||
625 | alter table prims change column `CameraAtOffsetX` `CameraAtOffsetX` double NOT NULL default '0'; | ||
626 | alter table prims change column `CameraAtOffsetY` `CameraAtOffsetY` double NOT NULL default '0'; | ||
627 | alter table prims change column `CameraAtOffsetZ` `CameraAtOffsetZ` double NOT NULL default '0'; | ||
628 | alter table prims change column `CollisionSoundVolume` `CollisionSoundVolume` double NOT NULL default '0'; | ||
629 | |||
630 | alter table primshapes change column `ScaleX` `ScaleX` double NOT NULL default '0'; | ||
631 | alter table primshapes change column `ScaleY` `ScaleY` double NOT NULL default '0'; | ||
632 | alter table primshapes change column `ScaleZ` `ScaleZ` double NOT NULL default '0'; | ||
633 | |||
634 | COMMIT; | ||
635 | |||
636 | :VERSION 26 #--------------------- | ||
637 | |||
638 | begin; | ||
639 | |||
640 | alter table prims change column `PositionX` `PositionX` double default NULL; | ||
641 | alter table prims change column `PositionY` `PositionY` double default NULL; | ||
642 | alter table prims change column `PositionZ` `PositionZ` double default NULL; | ||
643 | alter table prims change column `GroupPositionX` `GroupPositionX` double default NULL; | ||
644 | alter table prims change column `GroupPositionY` `GroupPositionY` double default NULL; | ||
645 | alter table prims change column `GroupPositionZ` `GroupPositionZ` double default NULL; | ||
646 | alter table prims change column `VelocityX` `VelocityX` double default NULL; | ||
647 | alter table prims change column `VelocityY` `VelocityY` double default NULL; | ||
648 | alter table prims change column `VelocityZ` `VelocityZ` double default NULL; | ||
649 | alter table prims change column `AngularVelocityX` `AngularVelocityX` double default NULL; | ||
650 | alter table prims change column `AngularVelocityY` `AngularVelocityY` double default NULL; | ||
651 | alter table prims change column `AngularVelocityZ` `AngularVelocityZ` double default NULL; | ||
652 | alter table prims change column `AccelerationX` `AccelerationX` double default NULL; | ||
653 | alter table prims change column `AccelerationY` `AccelerationY` double default NULL; | ||
654 | alter table prims change column `AccelerationZ` `AccelerationZ` double default NULL; | ||
655 | alter table prims change column `RotationX` `RotationX` double default NULL; | ||
656 | alter table prims change column `RotationY` `RotationY` double default NULL; | ||
657 | alter table prims change column `RotationZ` `RotationZ` double default NULL; | ||
658 | alter table prims change column `RotationW` `RotationW` double default NULL; | ||
659 | alter table prims change column `SitTargetOffsetX` `SitTargetOffsetX` double default NULL; | ||
660 | alter table prims change column `SitTargetOffsetY` `SitTargetOffsetY` double default NULL; | ||
661 | alter table prims change column `SitTargetOffsetZ` `SitTargetOffsetZ` double default NULL; | ||
662 | alter table prims change column `SitTargetOrientW` `SitTargetOrientW` double default NULL; | ||
663 | alter table prims change column `SitTargetOrientX` `SitTargetOrientX` double default NULL; | ||
664 | alter table prims change column `SitTargetOrientY` `SitTargetOrientY` double default NULL; | ||
665 | alter table prims change column `SitTargetOrientZ` `SitTargetOrientZ` double default NULL; | ||
666 | alter table prims change column `LoopedSoundGain` `LoopedSoundGain` double NOT NULL default '0'; | ||
667 | alter table prims change column `OmegaX` `OmegaX` double NOT NULL default '0'; | ||
668 | alter table prims change column `OmegaY` `OmegaY` double NOT NULL default '0'; | ||
669 | alter table prims change column `OmegaZ` `OmegaZ` double NOT NULL default '0'; | ||
670 | alter table prims change column `CameraEyeOffsetX` `CameraEyeOffsetX` double NOT NULL default '0'; | ||
671 | alter table prims change column `CameraEyeOffsetY` `CameraEyeOffsetY` double NOT NULL default '0'; | ||
672 | alter table prims change column `CameraEyeOffsetZ` `CameraEyeOffsetZ` double NOT NULL default '0'; | ||
673 | alter table prims change column `CameraAtOffsetX` `CameraAtOffsetX` double NOT NULL default '0'; | ||
674 | alter table prims change column `CameraAtOffsetY` `CameraAtOffsetY` double NOT NULL default '0'; | ||
675 | alter table prims change column `CameraAtOffsetZ` `CameraAtOffsetZ` double NOT NULL default '0'; | ||
676 | alter table prims change column `CollisionSoundVolume` `CollisionSoundVolume` double NOT NULL default '0'; | ||
677 | |||
678 | commit; | ||
679 | |||
680 | :VERSION 27 #--------------------- | ||
681 | |||
682 | BEGIN; | ||
683 | |||
684 | ALTER TABLE prims DROP COLUMN ParentID; | ||
685 | |||
686 | COMMIT; | ||
687 | |||
688 | :VERSION 28 #--------------------- | ||
689 | |||
690 | BEGIN; | ||
691 | |||
692 | update terrain | ||
693 | set RegionUUID = concat(substr(RegionUUID, 1, 8), "-", substr(RegionUUID, 9, 4), "-", substr(RegionUUID, 13, 4), "-", substr(RegionUUID, 17, 4), "-", substr(RegionUUID, 21, 12)) | ||
694 | where RegionUUID not like '%-%'; | ||
695 | |||
696 | |||
697 | update landaccesslist | ||
698 | set LandUUID = concat(substr(LandUUID, 1, 8), "-", substr(LandUUID, 9, 4), "-", substr(LandUUID, 13, 4), "-", substr(LandUUID, 17, 4), "-", substr(LandUUID, 21, 12)) | ||
699 | where LandUUID not like '%-%'; | ||
700 | |||
701 | update landaccesslist | ||
702 | set AccessUUID = concat(substr(AccessUUID, 1, 8), "-", substr(AccessUUID, 9, 4), "-", substr(AccessUUID, 13, 4), "-", substr(AccessUUID, 17, 4), "-", substr(AccessUUID, 21, 12)) | ||
703 | where AccessUUID not like '%-%'; | ||
704 | |||
705 | |||
706 | update prims | ||
707 | set UUID = concat(substr(UUID, 1, 8), "-", substr(UUID, 9, 4), "-", substr(UUID, 13, 4), "-", substr(UUID, 17, 4), "-", substr(UUID, 21, 12)) | ||
708 | where UUID not like '%-%'; | ||
709 | |||
710 | update prims | ||
711 | set RegionUUID = concat(substr(RegionUUID, 1, 8), "-", substr(RegionUUID, 9, 4), "-", substr(RegionUUID, 13, 4), "-", substr(RegionUUID, 17, 4), "-", substr(RegionUUID, 21, 12)) | ||
712 | where RegionUUID not like '%-%'; | ||
713 | |||
714 | update prims | ||
715 | set SceneGroupID = concat(substr(SceneGroupID, 1, 8), "-", substr(SceneGroupID, 9, 4), "-", substr(SceneGroupID, 13, 4), "-", substr(SceneGroupID, 17, 4), "-", substr(SceneGroupID, 21, 12)) | ||
716 | where SceneGroupID not like '%-%'; | ||
717 | |||
718 | update prims | ||
719 | set CreatorID = concat(substr(CreatorID, 1, 8), "-", substr(CreatorID, 9, 4), "-", substr(CreatorID, 13, 4), "-", substr(CreatorID, 17, 4), "-", substr(CreatorID, 21, 12)) | ||
720 | where CreatorID not like '%-%'; | ||
721 | |||
722 | update prims | ||
723 | set OwnerID = concat(substr(OwnerID, 1, 8), "-", substr(OwnerID, 9, 4), "-", substr(OwnerID, 13, 4), "-", substr(OwnerID, 17, 4), "-", substr(OwnerID, 21, 12)) | ||
724 | where OwnerID not like '%-%'; | ||
725 | |||
726 | update prims | ||
727 | set GroupID = concat(substr(GroupID, 1, 8), "-", substr(GroupID, 9, 4), "-", substr(GroupID, 13, 4), "-", substr(GroupID, 17, 4), "-", substr(GroupID, 21, 12)) | ||
728 | where GroupID not like '%-%'; | ||
729 | |||
730 | update prims | ||
731 | set LastOwnerID = concat(substr(LastOwnerID, 1, 8), "-", substr(LastOwnerID, 9, 4), "-", substr(LastOwnerID, 13, 4), "-", substr(LastOwnerID, 17, 4), "-", substr(LastOwnerID, 21, 12)) | ||
732 | where LastOwnerID not like '%-%'; | ||
733 | |||
734 | |||
735 | update primshapes | ||
736 | set UUID = concat(substr(UUID, 1, 8), "-", substr(UUID, 9, 4), "-", substr(UUID, 13, 4), "-", substr(UUID, 17, 4), "-", substr(UUID, 21, 12)) | ||
737 | where UUID not like '%-%'; | ||
738 | |||
739 | |||
740 | update land | ||
741 | set UUID = concat(substr(UUID, 1, 8), "-", substr(UUID, 9, 4), "-", substr(UUID, 13, 4), "-", substr(UUID, 17, 4), "-", substr(UUID, 21, 12)) | ||
742 | where UUID not like '%-%'; | ||
743 | |||
744 | update land | ||
745 | set RegionUUID = concat(substr(RegionUUID, 1, 8), "-", substr(RegionUUID, 9, 4), "-", substr(RegionUUID, 13, 4), "-", substr(RegionUUID, 17, 4), "-", substr(RegionUUID, 21, 12)) | ||
746 | where RegionUUID not like '%-%'; | ||
747 | |||
748 | update land | ||
749 | set OwnerUUID = concat(substr(OwnerUUID, 1, 8), "-", substr(OwnerUUID, 9, 4), "-", substr(OwnerUUID, 13, 4), "-", substr(OwnerUUID, 17, 4), "-", substr(OwnerUUID, 21, 12)) | ||
750 | where OwnerUUID not like '%-%'; | ||
751 | |||
752 | update land | ||
753 | set GroupUUID = concat(substr(GroupUUID, 1, 8), "-", substr(GroupUUID, 9, 4), "-", substr(GroupUUID, 13, 4), "-", substr(GroupUUID, 17, 4), "-", substr(GroupUUID, 21, 12)) | ||
754 | where GroupUUID not like '%-%'; | ||
755 | |||
756 | update land | ||
757 | set MediaTextureUUID = concat(substr(MediaTextureUUID, 1, 8), "-", substr(MediaTextureUUID, 9, 4), "-", substr(MediaTextureUUID, 13, 4), "-", substr(MediaTextureUUID, 17, 4), "-", substr(MediaTextureUUID, 21, 12)) | ||
758 | where MediaTextureUUID not like '%-%'; | ||
759 | |||
760 | update land | ||
761 | set SnapshotUUID = concat(substr(SnapshotUUID, 1, 8), "-", substr(SnapshotUUID, 9, 4), "-", substr(SnapshotUUID, 13, 4), "-", substr(SnapshotUUID, 17, 4), "-", substr(SnapshotUUID, 21, 12)) | ||
762 | where SnapshotUUID not like '%-%'; | ||
763 | |||
764 | update land | ||
765 | set AuthbuyerID = concat(substr(AuthbuyerID, 1, 8), "-", substr(AuthbuyerID, 9, 4), "-", substr(AuthbuyerID, 13, 4), "-", substr(AuthbuyerID, 17, 4), "-", substr(AuthbuyerID, 21, 12)) | ||
766 | where AuthbuyerID not like '%-%'; | ||
767 | |||
768 | COMMIT; | ||
769 | |||
770 | :VERSION 29 #--------------------- | ||
771 | |||
772 | BEGIN; | ||
773 | |||
774 | ALTER TABLE prims ADD COLUMN PassTouches tinyint not null default 0; | ||
775 | |||
776 | COMMIT; | ||
777 | |||
778 | :VERSION 30 #--------------------- | ||
779 | |||
780 | BEGIN; | ||
781 | |||
782 | ALTER TABLE regionsettings ADD COLUMN loaded_creation_date varchar(20) default NULL; | ||
783 | ALTER TABLE regionsettings ADD COLUMN loaded_creation_time varchar(20) default NULL; | ||
784 | ALTER TABLE regionsettings ADD COLUMN loaded_creation_id varchar(64) default NULL; | ||
785 | |||
786 | COMMIT; | ||
787 | |||
788 | :VERSION 31 #--------------------- | ||
789 | |||
790 | BEGIN; | ||
791 | |||
792 | ALTER TABLE regionsettings DROP COLUMN loaded_creation_date; | ||
793 | ALTER TABLE regionsettings DROP COLUMN loaded_creation_time; | ||
794 | ALTER TABLE regionsettings ADD COLUMN loaded_creation_datetime int unsigned NOT NULL default 0; | ||
795 | |||
796 | COMMIT; | ||
797 | |||
798 | :VERSION 32 #--------------------- | ||
799 | |||
800 | BEGIN; | ||
801 | CREATE TABLE `regionwindlight` ( | ||
802 | `region_id` varchar(36) NOT NULL DEFAULT '000000-0000-0000-0000-000000000000', | ||
803 | `water_color_r` float(9,6) unsigned NOT NULL DEFAULT '4.000000', | ||
804 | `water_color_g` float(9,6) unsigned NOT NULL DEFAULT '38.000000', | ||
805 | `water_color_b` float(9,6) unsigned NOT NULL DEFAULT '64.000000', | ||
806 | `water_fog_density_exponent` float(3,1) unsigned NOT NULL DEFAULT '4.0', | ||
807 | `underwater_fog_modifier` float(3,2) unsigned NOT NULL DEFAULT '0.25', | ||
808 | `reflection_wavelet_scale_1` float(3,1) unsigned NOT NULL DEFAULT '2.0', | ||
809 | `reflection_wavelet_scale_2` float(3,1) unsigned NOT NULL DEFAULT '2.0', | ||
810 | `reflection_wavelet_scale_3` float(3,1) unsigned NOT NULL DEFAULT '2.0', | ||
811 | `fresnel_scale` float(3,2) unsigned NOT NULL DEFAULT '0.40', | ||
812 | `fresnel_offset` float(3,2) unsigned NOT NULL DEFAULT '0.50', | ||
813 | `refract_scale_above` float(3,2) unsigned NOT NULL DEFAULT '0.03', | ||
814 | `refract_scale_below` float(3,2) unsigned NOT NULL DEFAULT '0.20', | ||
815 | `blur_multiplier` float(4,3) unsigned NOT NULL DEFAULT '0.040', | ||
816 | `big_wave_direction_x` float(3,2) NOT NULL DEFAULT '1.05', | ||
817 | `big_wave_direction_y` float(3,2) NOT NULL DEFAULT '-0.42', | ||
818 | `little_wave_direction_x` float(3,2) NOT NULL DEFAULT '1.11', | ||
819 | `little_wave_direction_y` float(3,2) NOT NULL DEFAULT '-1.16', | ||
820 | `normal_map_texture` varchar(36) NOT NULL DEFAULT '822ded49-9a6c-f61c-cb89-6df54f42cdf4', | ||
821 | `horizon_r` float(3,2) unsigned NOT NULL DEFAULT '0.25', | ||
822 | `horizon_g` float(3,2) unsigned NOT NULL DEFAULT '0.25', | ||
823 | `horizon_b` float(3,2) unsigned NOT NULL DEFAULT '0.32', | ||
824 | `horizon_i` float(3,2) unsigned NOT NULL DEFAULT '0.32', | ||
825 | `haze_horizon` float(3,2) unsigned NOT NULL DEFAULT '0.19', | ||
826 | `blue_density_r` float(3,2) unsigned NOT NULL DEFAULT '0.12', | ||
827 | `blue_density_g` float(3,2) unsigned NOT NULL DEFAULT '0.22', | ||
828 | `blue_density_b` float(3,2) unsigned NOT NULL DEFAULT '0.38', | ||
829 | `blue_density_i` float(3,2) unsigned NOT NULL DEFAULT '0.38', | ||
830 | `haze_density` float(3,2) unsigned NOT NULL DEFAULT '0.70', | ||
831 | `density_multiplier` float(3,2) unsigned NOT NULL DEFAULT '0.18', | ||
832 | `distance_multiplier` float(4,1) unsigned NOT NULL DEFAULT '0.8', | ||
833 | `max_altitude` int(4) unsigned NOT NULL DEFAULT '1605', | ||
834 | `sun_moon_color_r` float(3,2) unsigned NOT NULL DEFAULT '0.24', | ||
835 | `sun_moon_color_g` float(3,2) unsigned NOT NULL DEFAULT '0.26', | ||
836 | `sun_moon_color_b` float(3,2) unsigned NOT NULL DEFAULT '0.30', | ||
837 | `sun_moon_color_i` float(3,2) unsigned NOT NULL DEFAULT '0.30', | ||
838 | `sun_moon_position` float(4,3) unsigned NOT NULL DEFAULT '0.317', | ||
839 | `ambient_r` float(3,2) unsigned NOT NULL DEFAULT '0.35', | ||
840 | `ambient_g` float(3,2) unsigned NOT NULL DEFAULT '0.35', | ||
841 | `ambient_b` float(3,2) unsigned NOT NULL DEFAULT '0.35', | ||
842 | `ambient_i` float(3,2) unsigned NOT NULL DEFAULT '0.35', | ||
843 | `east_angle` float(3,2) unsigned NOT NULL DEFAULT '0.00', | ||
844 | `sun_glow_focus` float(3,2) unsigned NOT NULL DEFAULT '0.10', | ||
845 | `sun_glow_size` float(3,2) unsigned NOT NULL DEFAULT '1.75', | ||
846 | `scene_gamma` float(4,2) unsigned NOT NULL DEFAULT '1.00', | ||
847 | `star_brightness` float(3,2) unsigned NOT NULL DEFAULT '0.00', | ||
848 | `cloud_color_r` float(3,2) unsigned NOT NULL DEFAULT '0.41', | ||
849 | `cloud_color_g` float(3,2) unsigned NOT NULL DEFAULT '0.41', | ||
850 | `cloud_color_b` float(3,2) unsigned NOT NULL DEFAULT '0.41', | ||
851 | `cloud_color_i` float(3,2) unsigned NOT NULL DEFAULT '0.41', | ||
852 | `cloud_x` float(3,2) unsigned NOT NULL DEFAULT '1.00', | ||
853 | `cloud_y` float(3,2) unsigned NOT NULL DEFAULT '0.53', | ||
854 | `cloud_density` float(3,2) unsigned NOT NULL DEFAULT '1.00', | ||
855 | `cloud_coverage` float(3,2) unsigned NOT NULL DEFAULT '0.27', | ||
856 | `cloud_scale` float(3,2) unsigned NOT NULL DEFAULT '0.42', | ||
857 | `cloud_detail_x` float(3,2) unsigned NOT NULL DEFAULT '1.00', | ||
858 | `cloud_detail_y` float(3,2) unsigned NOT NULL DEFAULT '0.53', | ||
859 | `cloud_detail_density` float(3,2) unsigned NOT NULL DEFAULT '0.12', | ||
860 | `cloud_scroll_x` float(3,2) unsigned NOT NULL DEFAULT '0.20', | ||
861 | `cloud_scroll_x_lock` tinyint(1) unsigned NOT NULL DEFAULT '0', | ||
862 | `cloud_scroll_y` float(3,2) unsigned NOT NULL DEFAULT '0.01', | ||
863 | `cloud_scroll_y_lock` tinyint(1) unsigned NOT NULL DEFAULT '0', | ||
864 | `draw_classic_clouds` tinyint(1) unsigned NOT NULL DEFAULT '1', | ||
865 | PRIMARY KEY (`region_id`) | ||
866 | ); | ||
867 | |||
868 | ALTER TABLE estate_settings AUTO_INCREMENT = 100; | ||
869 | COMMIT; | ||
870 | |||
871 | :VERSION 33 #--------------------- | ||
872 | |||
873 | BEGIN; | ||
874 | ALTER TABLE regionsettings ADD map_tile_ID CHAR(36) NOT NULL DEFAULT '00000000-0000-0000-0000-000000000000'; | ||
875 | COMMIT; | ||
876 | |||
diff --git a/OpenSim/Data/MySQL/Resources/UserAccount.migrations b/OpenSim/Data/MySQL/Resources/UserAccount.migrations new file mode 100644 index 0000000..84011e6 --- /dev/null +++ b/OpenSim/Data/MySQL/Resources/UserAccount.migrations | |||
@@ -0,0 +1,47 @@ | |||
1 | :VERSION 1 # ------------------------- | ||
2 | |||
3 | BEGIN; | ||
4 | |||
5 | CREATE TABLE `UserAccounts` ( | ||
6 | `PrincipalID` CHAR(36) NOT NULL, | ||
7 | `ScopeID` CHAR(36) NOT NULL, | ||
8 | `FirstName` VARCHAR(64) NOT NULL, | ||
9 | `LastName` VARCHAR(64) NOT NULL, | ||
10 | `Email` VARCHAR(64), | ||
11 | `ServiceURLs` TEXT, | ||
12 | `Created` INT(11) | ||
13 | ) ENGINE=InnoDB DEFAULT CHARSET=utf8; | ||
14 | |||
15 | COMMIT; | ||
16 | |||
17 | :VERSION 2 # ------------------------- | ||
18 | |||
19 | BEGIN; | ||
20 | |||
21 | INSERT INTO UserAccounts (PrincipalID, ScopeID, FirstName, LastName, Email, ServiceURLs, Created) SELECT `UUID` AS PrincipalID, '00000000-0000-0000-0000-000000000000' AS ScopeID, username AS FirstName, lastname AS LastName, email as Email, CONCAT('AssetServerURI=', userAssetURI, ' InventoryServerURI=', userInventoryURI, ' GatewayURI= HomeURI=') AS ServiceURLs, created as Created FROM users; | ||
22 | |||
23 | COMMIT; | ||
24 | |||
25 | :VERSION 3 # ------------------------- | ||
26 | |||
27 | BEGIN; | ||
28 | |||
29 | CREATE UNIQUE INDEX PrincipalID ON UserAccounts(PrincipalID); | ||
30 | CREATE INDEX Email ON UserAccounts(Email); | ||
31 | CREATE INDEX FirstName ON UserAccounts(FirstName); | ||
32 | CREATE INDEX LastName ON UserAccounts(LastName); | ||
33 | CREATE INDEX Name ON UserAccounts(FirstName,LastName); | ||
34 | |||
35 | COMMIT; | ||
36 | |||
37 | :VERSION 4 # ------------------------- | ||
38 | |||
39 | BEGIN; | ||
40 | |||
41 | ALTER TABLE UserAccounts ADD COLUMN UserLevel integer NOT NULL DEFAULT 0; | ||
42 | ALTER TABLE UserAccounts ADD COLUMN UserFlags integer NOT NULL DEFAULT 0; | ||
43 | ALTER TABLE UserAccounts ADD COLUMN UserTitle varchar(64) NOT NULL DEFAULT ''; | ||
44 | |||
45 | COMMIT; | ||
46 | |||
47 | |||
diff --git a/OpenSim/Data/MySQL/Resources/001_UserStore.sql b/OpenSim/Data/MySQL/Resources/UserStore.migrations index 29ebc7d..f054611 100644 --- a/OpenSim/Data/MySQL/Resources/001_UserStore.sql +++ b/OpenSim/Data/MySQL/Resources/UserStore.migrations | |||
@@ -1,3 +1,5 @@ | |||
1 | :VERSION 1 # ----------------------------- | ||
2 | |||
1 | BEGIN; | 3 | BEGIN; |
2 | 4 | ||
3 | SET FOREIGN_KEY_CHECKS=0; | 5 | SET FOREIGN_KEY_CHECKS=0; |
@@ -104,4 +106,63 @@ CREATE TABLE `users` ( | |||
104 | -- ---------------------------- | 106 | -- ---------------------------- |
105 | -- Records | 107 | -- Records |
106 | -- ---------------------------- | 108 | -- ---------------------------- |
107 | COMMIT; \ No newline at end of file | 109 | COMMIT; |
110 | |||
111 | :VERSION 2 # ----------------------------- | ||
112 | |||
113 | BEGIN; | ||
114 | |||
115 | ALTER TABLE users add homeRegionID char(36) NOT NULL default '00000000-0000-0000-0000-000000000000'; | ||
116 | |||
117 | COMMIT; | ||
118 | |||
119 | :VERSION 3 # ----------------------------- | ||
120 | |||
121 | BEGIN; | ||
122 | |||
123 | ALTER TABLE users add userFlags integer NOT NULL default 0; | ||
124 | ALTER TABLE users add godLevel integer NOT NULL default 0; | ||
125 | |||
126 | COMMIT; | ||
127 | |||
128 | :VERSION 4 # ----------------------------- | ||
129 | |||
130 | BEGIN; | ||
131 | |||
132 | ALTER TABLE users add customType varchar(32) not null default ''; | ||
133 | ALTER TABLE users add partner char(36) not null default '00000000-0000-0000-0000-000000000000'; | ||
134 | |||
135 | COMMIT; | ||
136 | |||
137 | :VERSION 5 # ----------------------------- | ||
138 | |||
139 | BEGIN; | ||
140 | |||
141 | CREATE TABLE `avatarattachments` (`UUID` char(36) NOT NULL, `attachpoint` int(11) NOT NULL, `item` char(36) NOT NULL, `asset` char(36) NOT NULL) ENGINE=InnoDB; | ||
142 | |||
143 | COMMIT; | ||
144 | |||
145 | :VERSION 6 # ----------------------------- | ||
146 | |||
147 | BEGIN; | ||
148 | |||
149 | ALTER TABLE agents add currentLookAt varchar(36) not null default ''; | ||
150 | |||
151 | COMMIT; | ||
152 | |||
153 | :VERSION 7 # ----------------------------- | ||
154 | |||
155 | BEGIN; | ||
156 | |||
157 | ALTER TABLE users add email varchar(250); | ||
158 | |||
159 | COMMIT; | ||
160 | |||
161 | :VERSION 8 # ----------------------------- | ||
162 | |||
163 | BEGIN; | ||
164 | |||
165 | ALTER TABLE users add scopeID char(36) not null default '00000000-0000-0000-0000-000000000000'; | ||
166 | |||
167 | COMMIT; | ||
168 | |||