diff options
author | Diva Canto | 2011-04-28 07:28:29 -0700 |
---|---|---|
committer | Justin Clark-Casey (justincc) | 2011-04-29 00:33:10 +0100 |
commit | 975cebea0b639a235ce1b13d6de66abef04d6df8 (patch) | |
tree | a696a0f184def95c5c1e8e73b54cd3696b23236e /OpenSim/Data/MSSQL/Resources | |
parent | Stop CHANGED_INVENTORY firing twice if a notecard is edited in prim. (diff) | |
download | opensim-SC_OLD-975cebea0b639a235ce1b13d6de66abef04d6df8.zip opensim-SC_OLD-975cebea0b639a235ce1b13d6de66abef04d6df8.tar.gz opensim-SC_OLD-975cebea0b639a235ce1b13d6de66abef04d6df8.tar.bz2 opensim-SC_OLD-975cebea0b639a235ce1b13d6de66abef04d6df8.tar.xz |
Thank you MrMonkE for a patch that seems to bring the MSSQL data layer up to speed with 0.7.x.
Diffstat (limited to 'OpenSim/Data/MSSQL/Resources')
-rw-r--r-- | OpenSim/Data/MSSQL/Resources/AuthStore.migrations | 8 | ||||
-rw-r--r-- | OpenSim/Data/MSSQL/Resources/Avatar.migrations | 25 | ||||
-rw-r--r-- | OpenSim/Data/MSSQL/Resources/FriendsStore.migrations | 4 | ||||
-rw-r--r-- | OpenSim/Data/MSSQL/Resources/GridStore.migrations | 13 | ||||
-rw-r--r-- | OpenSim/Data/MSSQL/Resources/InventoryStore.migrations | 9 | ||||
-rw-r--r-- | OpenSim/Data/MSSQL/Resources/Presence.migrations | 17 | ||||
-rw-r--r-- | OpenSim/Data/MSSQL/Resources/RegionStore.migrations | 119 | ||||
-rw-r--r-- | OpenSim/Data/MSSQL/Resources/UserAccount.migrations | 2 |
8 files changed, 176 insertions, 21 deletions
diff --git a/OpenSim/Data/MSSQL/Resources/AuthStore.migrations b/OpenSim/Data/MSSQL/Resources/AuthStore.migrations index 5b90ca3..eb91296 100644 --- a/OpenSim/Data/MSSQL/Resources/AuthStore.migrations +++ b/OpenSim/Data/MSSQL/Resources/AuthStore.migrations | |||
@@ -22,7 +22,11 @@ COMMIT | |||
22 | 22 | ||
23 | BEGIN TRANSACTION | 23 | BEGIN TRANSACTION |
24 | 24 | ||
25 | INSERT INTO auth (UUID, passwordHash, passwordSalt, webLoginKey, accountType) SELECT [UUID] AS UUID, [passwordHash] AS passwordHash, [passwordSalt] AS passwordSalt, [webLoginKey] AS webLoginKey, 'UserAccount' as [accountType] FROM users; | 25 | IF EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[users]') AND type in (N'U')) |
26 | INSERT INTO auth (UUID, passwordHash, passwordSalt, webLoginKey, accountType) SELECT [UUID] AS UUID, [passwordHash] AS passwordHash, [passwordSalt] AS passwordSalt, [webLoginKey] AS webLoginKey, 'UserAccount' as [accountType] FROM users; | ||
27 | |||
28 | COMMIT | ||
29 | |||
30 | |||
26 | 31 | ||
27 | 32 | ||
28 | COMMIT \ No newline at end of file | ||
diff --git a/OpenSim/Data/MSSQL/Resources/Avatar.migrations b/OpenSim/Data/MSSQL/Resources/Avatar.migrations index 759e939..5364153 100644 --- a/OpenSim/Data/MSSQL/Resources/Avatar.migrations +++ b/OpenSim/Data/MSSQL/Resources/Avatar.migrations | |||
@@ -13,5 +13,28 @@ PRIMARY KEY CLUSTERED | |||
13 | ) ON [PRIMARY] | 13 | ) ON [PRIMARY] |
14 | 14 | ||
15 | 15 | ||
16 | COMMIT | ||
17 | |||
18 | :VERSION 2 | ||
19 | |||
20 | BEGIN TRANSACTION | ||
21 | |||
22 | CREATE TABLE dbo.Tmp_Avatars | ||
23 | ( | ||
24 | PrincipalID uniqueidentifier NOT NULL, | ||
25 | [Name] varchar(32) NOT NULL, | ||
26 | Value text NOT NULL DEFAULT '', | ||
27 | ) ON [PRIMARY] | ||
28 | TEXTIMAGE_ON [PRIMARY] | ||
29 | |||
30 | IF EXISTS(SELECT * FROM dbo.Avatars) | ||
31 | EXEC('INSERT INTO dbo.Tmp_Avatars (PrincipalID, Name, Value) | ||
32 | SELECT PrincipalID, CONVERT(text, Name), Value FROM dbo.Avatars WITH (HOLDLOCK TABLOCKX)') | ||
33 | |||
34 | DROP TABLE dbo.Avatars | ||
35 | |||
36 | EXECUTE sp_rename N'dbo.Tmp_Avatars', N'Avatars', 'OBJECT' | ||
37 | |||
38 | COMMIT | ||
39 | |||
16 | 40 | ||
17 | COMMIT \ No newline at end of file | ||
diff --git a/OpenSim/Data/MSSQL/Resources/FriendsStore.migrations b/OpenSim/Data/MSSQL/Resources/FriendsStore.migrations index f981a91..4d8ab0f 100644 --- a/OpenSim/Data/MSSQL/Resources/FriendsStore.migrations +++ b/OpenSim/Data/MSSQL/Resources/FriendsStore.migrations | |||
@@ -15,6 +15,8 @@ COMMIT | |||
15 | 15 | ||
16 | BEGIN TRANSACTION | 16 | BEGIN TRANSACTION |
17 | 17 | ||
18 | INSERT INTO Friends (PrincipalID, Friend, Flags, Offered) SELECT [ownerID], [friendID], [friendPerms], 0 FROM userfriends; | 18 | IF EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[userfriends]') AND type in (N'U')) |
19 | INSERT INTO Friends (PrincipalID, Friend, Flags, Offered) | ||
20 | SELECT [ownerID], [friendID], [friendPerms], 0 FROM userfriends; | ||
19 | 21 | ||
20 | COMMIT \ No newline at end of file | 22 | COMMIT \ No newline at end of file |
diff --git a/OpenSim/Data/MSSQL/Resources/GridStore.migrations b/OpenSim/Data/MSSQL/Resources/GridStore.migrations index d2ca27a..c6342fc 100644 --- a/OpenSim/Data/MSSQL/Resources/GridStore.migrations +++ b/OpenSim/Data/MSSQL/Resources/GridStore.migrations | |||
@@ -222,4 +222,17 @@ ALTER TABLE [regions] ADD [Token] varchar(255) NOT NULL DEFAULT 0; | |||
222 | 222 | ||
223 | COMMIT | 223 | COMMIT |
224 | 224 | ||
225 | :VERSION 8 | ||
225 | 226 | ||
227 | BEGIN TRANSACTION | ||
228 | ALTER TABLE regions ALTER COLUMN regionName VarChar(128) | ||
229 | |||
230 | DROP INDEX IX_regions_name ON dbo.regions | ||
231 | ALTER TABLE regions ALTER COLUMN regionName VarChar(128) null | ||
232 | |||
233 | CREATE NONCLUSTERED INDEX IX_regions_name ON dbo.regions | ||
234 | ( | ||
235 | regionName | ||
236 | ) WITH( STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY] | ||
237 | |||
238 | COMMIT \ No newline at end of file | ||
diff --git a/OpenSim/Data/MSSQL/Resources/InventoryStore.migrations b/OpenSim/Data/MSSQL/Resources/InventoryStore.migrations index e2a8d57..4a3cb27 100644 --- a/OpenSim/Data/MSSQL/Resources/InventoryStore.migrations +++ b/OpenSim/Data/MSSQL/Resources/InventoryStore.migrations | |||
@@ -238,7 +238,10 @@ alter table inventoryitems | |||
238 | 238 | ||
239 | COMMIT | 239 | COMMIT |
240 | 240 | ||
241 | 241 | :VERSION 8 | |
242 | |||
243 | |||
244 | 242 | ||
243 | ALTER TABLE inventoryitems | ||
244 | ADD CONSTRAINT DF_inventoryitems_creatorID | ||
245 | DEFAULT '00000000-0000-0000-0000-000000000000' FOR creatorID | ||
246 | |||
247 | :GO \ No newline at end of file | ||
diff --git a/OpenSim/Data/MSSQL/Resources/Presence.migrations b/OpenSim/Data/MSSQL/Resources/Presence.migrations index 35f78e1..bcb6328 100644 --- a/OpenSim/Data/MSSQL/Resources/Presence.migrations +++ b/OpenSim/Data/MSSQL/Resources/Presence.migrations | |||
@@ -7,14 +7,7 @@ CREATE TABLE [Presence] ( | |||
7 | [RegionID] uniqueidentifier NOT NULL, | 7 | [RegionID] uniqueidentifier NOT NULL, |
8 | [SessionID] uniqueidentifier NOT NULL DEFAULT '00000000-0000-0000-0000-000000000000', | 8 | [SessionID] uniqueidentifier NOT NULL DEFAULT '00000000-0000-0000-0000-000000000000', |
9 | [SecureSessionID] uniqueidentifier NOT NULL DEFAULT '00000000-0000-0000-0000-000000000000', | 9 | [SecureSessionID] uniqueidentifier NOT NULL DEFAULT '00000000-0000-0000-0000-000000000000', |
10 | [Online] char(5) NOT NULL DEFAULT 'false', | 10 | |
11 | [Login] char(16) NOT NULL DEFAULT '0', | ||
12 | [Logout] char(16) NOT NULL DEFAULT '0', | ||
13 | [Position] char(64) NOT NULL DEFAULT '<0,0,0>', | ||
14 | [LookAt] char(64) NOT NULL DEFAULT '<0,0,0>', | ||
15 | [HomeRegionID] uniqueidentifier NOT NULL, | ||
16 | [HomePosition] CHAR(64) NOT NULL DEFAULT '<0,0,0>', | ||
17 | [HomeLookAt] CHAR(64) NOT NULL DEFAULT '<0,0,0>', | ||
18 | ) | 11 | ) |
19 | ON [PRIMARY] | 12 | ON [PRIMARY] |
20 | 13 | ||
@@ -27,4 +20,12 @@ BEGIN TRANSACTION | |||
27 | CREATE UNIQUE INDEX SessionID ON Presence(SessionID); | 20 | CREATE UNIQUE INDEX SessionID ON Presence(SessionID); |
28 | CREATE INDEX UserID ON Presence(UserID); | 21 | CREATE INDEX UserID ON Presence(UserID); |
29 | 22 | ||
23 | COMMIT | ||
24 | |||
25 | :VERSION 2 | ||
26 | |||
27 | BEGIN TRANSACTION | ||
28 | |||
29 | ALTER TABLE Presence ADD LastSeen DateTime | ||
30 | |||
30 | COMMIT \ No newline at end of file | 31 | COMMIT \ No newline at end of file |
diff --git a/OpenSim/Data/MSSQL/Resources/RegionStore.migrations b/OpenSim/Data/MSSQL/Resources/RegionStore.migrations index e2e8cbb..340b63d 100644 --- a/OpenSim/Data/MSSQL/Resources/RegionStore.migrations +++ b/OpenSim/Data/MSSQL/Resources/RegionStore.migrations | |||
@@ -1,4 +1,3 @@ | |||
1 | |||
2 | :VERSION 1 | 1 | :VERSION 1 |
3 | 2 | ||
4 | CREATE TABLE [dbo].[prims]( | 3 | CREATE TABLE [dbo].[prims]( |
@@ -926,11 +925,121 @@ ALTER TABLE regionsettings ADD loaded_creation_datetime int NOT NULL default 0 | |||
926 | COMMIT | 925 | COMMIT |
927 | 926 | ||
928 | :VERSION 24 | 927 | :VERSION 24 |
929 | -- Added post 0.7 | ||
930 | 928 | ||
931 | BEGIN TRANSACTION | 929 | BEGIN TRANSACTION |
932 | 930 | ||
933 | ALTER TABLE prims ADD COLUMN MediaURL varchar(255) | 931 | ALTER TABLE prims ADD MediaURL varchar(255) |
934 | ALTER TABLE primshapes ADD COLUMN Media TEXT | 932 | ALTER TABLE primshapes ADD Media TEXT NULL |
933 | |||
934 | COMMIT | ||
935 | |||
936 | :VERSION 25 | ||
937 | |||
938 | BEGIN TRANSACTION | ||
939 | CREATE TABLE "regionwindlight" ( | ||
940 | "region_id" varchar(36) NOT NULL DEFAULT '000000-0000-0000-0000-000000000000', | ||
941 | "water_color_r" [float] NOT NULL DEFAULT '4.000000', | ||
942 | "water_color_g" [float] NOT NULL DEFAULT '38.000000', | ||
943 | "water_color_b" [float] NOT NULL DEFAULT '64.000000', | ||
944 | "water_fog_density_exponent" [float] NOT NULL DEFAULT '4.0', | ||
945 | "underwater_fog_modifier" [float] NOT NULL DEFAULT '0.25', | ||
946 | "reflection_wavelet_scale_1" [float] NOT NULL DEFAULT '2.0', | ||
947 | "reflection_wavelet_scale_2" [float] NOT NULL DEFAULT '2.0', | ||
948 | "reflection_wavelet_scale_3" [float] NOT NULL DEFAULT '2.0', | ||
949 | "fresnel_scale" [float] NOT NULL DEFAULT '0.40', | ||
950 | "fresnel_offset" [float] NOT NULL DEFAULT '0.50', | ||
951 | "refract_scale_above" [float] NOT NULL DEFAULT '0.03', | ||
952 | "refract_scale_below" [float] NOT NULL DEFAULT '0.20', | ||
953 | "blur_multiplier" [float] NOT NULL DEFAULT '0.040', | ||
954 | "big_wave_direction_x" [float] NOT NULL DEFAULT '1.05', | ||
955 | "big_wave_direction_y" [float] NOT NULL DEFAULT '-0.42', | ||
956 | "little_wave_direction_x" [float] NOT NULL DEFAULT '1.11', | ||
957 | "little_wave_direction_y" [float] NOT NULL DEFAULT '-1.16', | ||
958 | "normal_map_texture" varchar(36) NOT NULL DEFAULT '822ded49-9a6c-f61c-cb89-6df54f42cdf4', | ||
959 | "horizon_r" [float] NOT NULL DEFAULT '0.25', | ||
960 | "horizon_g" [float] NOT NULL DEFAULT '0.25', | ||
961 | "horizon_b" [float] NOT NULL DEFAULT '0.32', | ||
962 | "horizon_i" [float] NOT NULL DEFAULT '0.32', | ||
963 | "haze_horizon" [float] NOT NULL DEFAULT '0.19', | ||
964 | "blue_density_r" [float] NOT NULL DEFAULT '0.12', | ||
965 | "blue_density_g" [float] NOT NULL DEFAULT '0.22', | ||
966 | "blue_density_b" [float] NOT NULL DEFAULT '0.38', | ||
967 | "blue_density_i" [float] NOT NULL DEFAULT '0.38', | ||
968 | "haze_density" [float] NOT NULL DEFAULT '0.70', | ||
969 | "density_multiplier" [float] NOT NULL DEFAULT '0.18', | ||
970 | "distance_multiplier" [float] NOT NULL DEFAULT '0.8', | ||
971 | "max_altitude" int NOT NULL DEFAULT '1605', | ||
972 | "sun_moon_color_r" [float] NOT NULL DEFAULT '0.24', | ||
973 | "sun_moon_color_g" [float] NOT NULL DEFAULT '0.26', | ||
974 | "sun_moon_color_b" [float] NOT NULL DEFAULT '0.30', | ||
975 | "sun_moon_color_i" [float] NOT NULL DEFAULT '0.30', | ||
976 | "sun_moon_position" [float] NOT NULL DEFAULT '0.317', | ||
977 | "ambient_r" [float] NOT NULL DEFAULT '0.35', | ||
978 | "ambient_g" [float] NOT NULL DEFAULT '0.35', | ||
979 | "ambient_b" [float] NOT NULL DEFAULT '0.35', | ||
980 | "ambient_i" [float] NOT NULL DEFAULT '0.35', | ||
981 | "east_angle" [float] NOT NULL DEFAULT '0.00', | ||
982 | "sun_glow_focus" [float] NOT NULL DEFAULT '0.10', | ||
983 | "sun_glow_size" [float] NOT NULL DEFAULT '1.75', | ||
984 | "scene_gamma" [float] NOT NULL DEFAULT '1.00', | ||
985 | "star_brightness" [float] NOT NULL DEFAULT '0.00', | ||
986 | "cloud_color_r" [float] NOT NULL DEFAULT '0.41', | ||
987 | "cloud_color_g" [float] NOT NULL DEFAULT '0.41', | ||
988 | "cloud_color_b" [float] NOT NULL DEFAULT '0.41', | ||
989 | "cloud_color_i" [float] NOT NULL DEFAULT '0.41', | ||
990 | "cloud_x" [float] NOT NULL DEFAULT '1.00', | ||
991 | "cloud_y" [float] NOT NULL DEFAULT '0.53', | ||
992 | "cloud_density" [float] NOT NULL DEFAULT '1.00', | ||
993 | "cloud_coverage" [float] NOT NULL DEFAULT '0.27', | ||
994 | "cloud_scale" [float] NOT NULL DEFAULT '0.42', | ||
995 | "cloud_detail_x" [float] NOT NULL DEFAULT '1.00', | ||
996 | "cloud_detail_y" [float] NOT NULL DEFAULT '0.53', | ||
997 | "cloud_detail_density" [float] NOT NULL DEFAULT '0.12', | ||
998 | "cloud_scroll_x" [float] NOT NULL DEFAULT '0.20', | ||
999 | "cloud_scroll_x_lock" tinyint NOT NULL DEFAULT '0', | ||
1000 | "cloud_scroll_y" [float] NOT NULL DEFAULT '0.01', | ||
1001 | "cloud_scroll_y_lock" tinyint NOT NULL DEFAULT '0', | ||
1002 | "draw_classic_clouds" tinyint NOT NULL DEFAULT '1', | ||
1003 | PRIMARY KEY ("region_id") | ||
1004 | ) | ||
1005 | |||
1006 | COMMIT TRANSACTION | ||
1007 | |||
1008 | :VERSION 26 | ||
1009 | |||
1010 | BEGIN TRANSACTION | ||
1011 | |||
1012 | ALTER TABLE regionsettings ADD map_tile_ID CHAR(36) NOT NULL DEFAULT '00000000-0000-0000-0000-000000000000' | ||
1013 | |||
1014 | COMMIT | ||
1015 | |||
1016 | :VERSION 27 #--------------------- | ||
935 | 1017 | ||
936 | COMMIT \ No newline at end of file | 1018 | BEGIN TRANSACTION |
1019 | ALTER TABLE land ADD MediaType VARCHAR(32) NOT NULL DEFAULT 'none/none' | ||
1020 | ALTER TABLE land ADD MediaDescription VARCHAR(255) NOT NULL DEFAULT '' | ||
1021 | ALTER TABLE land ADD MediaSize VARCHAR(16) NOT NULL DEFAULT '0,0' | ||
1022 | ALTER TABLE land ADD MediaLoop bit NOT NULL DEFAULT 0 | ||
1023 | ALTER TABLE land ADD ObscureMusic bit NOT NULL DEFAULT 0 | ||
1024 | ALTER TABLE land ADD ObscureMedia bit NOT NULL DEFAULT 0 | ||
1025 | COMMIT | ||
1026 | |||
1027 | :VERSION 28 #--------------------- | ||
1028 | |||
1029 | BEGIN TRANSACTION | ||
1030 | |||
1031 | ALTER TABLE prims | ||
1032 | ADD CONSTRAINT DF_prims_CreatorID | ||
1033 | DEFAULT '00000000-0000-0000-0000-000000000000' | ||
1034 | FOR CreatorID | ||
1035 | |||
1036 | ALTER TABLE prims ALTER COLUMN CreatorID uniqueidentifier NOT NULL | ||
1037 | |||
1038 | ALTER TABLE primitems | ||
1039 | ADD CONSTRAINT DF_primitems_CreatorID | ||
1040 | DEFAULT '00000000-0000-0000-0000-000000000000' | ||
1041 | FOR CreatorID | ||
1042 | |||
1043 | ALTER TABLE primitems ALTER COLUMN CreatorID uniqueidentifier NOT NULL | ||
1044 | |||
1045 | COMMIT | ||
diff --git a/OpenSim/Data/MSSQL/Resources/UserAccount.migrations b/OpenSim/Data/MSSQL/Resources/UserAccount.migrations index 8534e23..a81704d 100644 --- a/OpenSim/Data/MSSQL/Resources/UserAccount.migrations +++ b/OpenSim/Data/MSSQL/Resources/UserAccount.migrations | |||
@@ -19,7 +19,7 @@ CREATE TABLE [UserAccounts] ( | |||
19 | :VERSION 2 | 19 | :VERSION 2 |
20 | 20 | ||
21 | BEGIN TRANSACTION | 21 | BEGIN TRANSACTION |
22 | 22 | IF EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[users]') AND type in (N'U')) | |
23 | INSERT INTO UserAccounts (PrincipalID, ScopeID, FirstName, LastName, Email, ServiceURLs, Created) SELECT [UUID] AS PrincipalID, '00000000-0000-0000-0000-000000000000' AS ScopeID, | 23 | INSERT INTO UserAccounts (PrincipalID, ScopeID, FirstName, LastName, Email, ServiceURLs, Created) SELECT [UUID] AS PrincipalID, '00000000-0000-0000-0000-000000000000' AS ScopeID, |
24 | username AS FirstName, | 24 | username AS FirstName, |
25 | lastname AS LastName, | 25 | lastname AS LastName, |