aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Data/MSSQL/Resources/001_UserStore.sql
diff options
context:
space:
mode:
authorMelanie Thielker2008-09-14 13:23:02 +0000
committerMelanie Thielker2008-09-14 13:23:02 +0000
commit281955949910eb257b5f7e42e54535ba7812418e (patch)
tree8c62c0006f2567983a686e811513c8c009061aac /OpenSim/Data/MSSQL/Resources/001_UserStore.sql
parent* Converted a number of methods within the login processes from private to pr... (diff)
downloadopensim-SC-281955949910eb257b5f7e42e54535ba7812418e.zip
opensim-SC-281955949910eb257b5f7e42e54535ba7812418e.tar.gz
opensim-SC-281955949910eb257b5f7e42e54535ba7812418e.tar.bz2
opensim-SC-281955949910eb257b5f7e42e54535ba7812418e.tar.xz
Mantis #2124
Thank you, RuudL, for a patch that brings MSSQL up to the same implementation level as MySQL.
Diffstat (limited to 'OpenSim/Data/MSSQL/Resources/001_UserStore.sql')
-rw-r--r--OpenSim/Data/MSSQL/Resources/001_UserStore.sql224
1 files changed, 224 insertions, 0 deletions
diff --git a/OpenSim/Data/MSSQL/Resources/001_UserStore.sql b/OpenSim/Data/MSSQL/Resources/001_UserStore.sql
new file mode 100644
index 0000000..abd6ff2
--- /dev/null
+++ b/OpenSim/Data/MSSQL/Resources/001_UserStore.sql
@@ -0,0 +1,224 @@
1CREATE TABLE [users] (
2 [UUID] [varchar](36) NOT NULL default '',
3 [username] [varchar](32) NOT NULL,
4 [lastname] [varchar](32) NOT NULL,
5 [passwordHash] [varchar](32) NOT NULL,
6 [passwordSalt] [varchar](32) NOT NULL,
7 [homeRegion] [bigint] default NULL,
8 [homeLocationX] [float] default NULL,
9 [homeLocationY] [float] default NULL,
10 [homeLocationZ] [float] default NULL,
11 [homeLookAtX] [float] default NULL,
12 [homeLookAtY] [float] default NULL,
13 [homeLookAtZ] [float] default NULL,
14 [created] [int] NOT NULL,
15 [lastLogin] [int] NOT NULL,
16 [userInventoryURI] [varchar](255) default NULL,
17 [userAssetURI] [varchar](255) default NULL,
18 [profileCanDoMask] [int] default NULL,
19 [profileWantDoMask] [int] default NULL,
20 [profileAboutText] [ntext],
21 [profileFirstText] [ntext],
22 [profileImage] [varchar](36) default NULL,
23 [profileFirstImage] [varchar](36) default NULL,
24 [webLoginKey] [varchar](36) default NULL,
25 PRIMARY KEY CLUSTERED
26(
27 [UUID] ASC
28)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
29) ON [PRIMARY]
30
31
32CREATE NONCLUSTERED INDEX [usernames] ON [users]
33(
34 [username] ASC,
35 [lastname] ASC
36)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
37
38
39CREATE TABLE [agents] (
40 [UUID] [varchar](36) NOT NULL,
41 [sessionID] [varchar](36) NOT NULL,
42 [secureSessionID] [varchar](36) NOT NULL,
43 [agentIP] [varchar](16) NOT NULL,
44 [agentPort] [int] NOT NULL,
45 [agentOnline] [tinyint] NOT NULL,
46 [loginTime] [int] NOT NULL,
47 [logoutTime] [int] NOT NULL,
48 [currentRegion] [varchar](36) NOT NULL,
49 [currentHandle] [bigint] NOT NULL,
50 [currentPos] [varchar](64) NOT NULL,
51 PRIMARY KEY CLUSTERED
52(
53 [UUID] ASC
54)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
55) ON [PRIMARY]
56
57
58CREATE NONCLUSTERED INDEX [session] ON [agents]
59(
60 [sessionID] ASC
61)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
62
63CREATE NONCLUSTERED INDEX [ssession] ON [agents]
64(
65 [secureSessionID] ASC
66)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
67
68
69CREATE TABLE [dbo].[userfriends](
70 [ownerID] [varchar](50) COLLATE Latin1_General_CI_AS NOT NULL,
71 [friendID] [varchar](50) COLLATE Latin1_General_CI_AS NOT NULL,
72 [friendPerms] [nvarchar](50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
73 [datetimestamp] [nvarchar](50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
74) ON [PRIMARY]
75
76CREATE TABLE [avatarappearance] (
77 [Owner] [varchar](36) NOT NULL,
78 [Serial] int NOT NULL,
79 [Visual_Params] [image] NOT NULL,
80 [Texture] [image] NOT NULL,
81 [Avatar_Height] float NOT NULL,
82 [Body_Item] [varchar](36) NOT NULL,
83 [Body_Asset] [varchar](36) NOT NULL,
84 [Skin_Item] [varchar](36) NOT NULL,
85 [Skin_Asset] [varchar](36) NOT NULL,
86 [Hair_Item] [varchar](36) NOT NULL,
87 [Hair_Asset] [varchar](36) NOT NULL,
88 [Eyes_Item] [varchar](36) NOT NULL,
89 [Eyes_Asset] [varchar](36) NOT NULL,
90 [Shirt_Item] [varchar](36) NOT NULL,
91 [Shirt_Asset] [varchar](36) NOT NULL,
92 [Pants_Item] [varchar](36) NOT NULL,
93 [Pants_Asset] [varchar](36) NOT NULL,
94 [Shoes_Item] [varchar](36) NOT NULL,
95 [Shoes_Asset] [varchar](36) NOT NULL,
96 [Socks_Item] [varchar](36) NOT NULL,
97 [Socks_Asset] [varchar](36) NOT NULL,
98 [Jacket_Item] [varchar](36) NOT NULL,
99 [Jacket_Asset] [varchar](36) NOT NULL,
100 [Gloves_Item] [varchar](36) NOT NULL,
101 [Gloves_Asset] [varchar](36) NOT NULL,
102 [Undershirt_Item] [varchar](36) NOT NULL,
103 [Undershirt_Asset] [varchar](36) NOT NULL,
104 [Underpants_Item] [varchar](36) NOT NULL,
105 [Underpants_Asset] [varchar](36) NOT NULL,
106 [Skirt_Item] [varchar](36) NOT NULL,
107 [Skirt_Asset] [varchar](36) NOT NULL,
108
109 PRIMARY KEY CLUSTERED (
110 [Owner]
111 ) WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
112) ON [PRIMARY]
113CREATE TABLE [users] (
114 [UUID] [varchar](36) NOT NULL default '',
115 [username] [varchar](32) NOT NULL,
116 [lastname] [varchar](32) NOT NULL,
117 [passwordHash] [varchar](32) NOT NULL,
118 [passwordSalt] [varchar](32) NOT NULL,
119 [homeRegion] [bigint] default NULL,
120 [homeLocationX] [float] default NULL,
121 [homeLocationY] [float] default NULL,
122 [homeLocationZ] [float] default NULL,
123 [homeLookAtX] [float] default NULL,
124 [homeLookAtY] [float] default NULL,
125 [homeLookAtZ] [float] default NULL,
126 [created] [int] NOT NULL,
127 [lastLogin] [int] NOT NULL,
128 [userInventoryURI] [varchar](255) default NULL,
129 [userAssetURI] [varchar](255) default NULL,
130 [profileCanDoMask] [int] default NULL,
131 [profileWantDoMask] [int] default NULL,
132 [profileAboutText] [ntext],
133 [profileFirstText] [ntext],
134 [profileImage] [varchar](36) default NULL,
135 [profileFirstImage] [varchar](36) default NULL,
136 [webLoginKey] [varchar](36) default NULL,
137 PRIMARY KEY CLUSTERED
138(
139 [UUID] ASC
140)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
141) ON [PRIMARY]
142
143
144CREATE NONCLUSTERED INDEX [usernames] ON [users]
145(
146 [username] ASC,
147 [lastname] ASC
148)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
149
150
151CREATE TABLE [agents] (
152 [UUID] [varchar](36) NOT NULL,
153 [sessionID] [varchar](36) NOT NULL,
154 [secureSessionID] [varchar](36) NOT NULL,
155 [agentIP] [varchar](16) NOT NULL,
156 [agentPort] [int] NOT NULL,
157 [agentOnline] [tinyint] NOT NULL,
158 [loginTime] [int] NOT NULL,
159 [logoutTime] [int] NOT NULL,
160 [currentRegion] [varchar](36) NOT NULL,
161 [currentHandle] [bigint] NOT NULL,
162 [currentPos] [varchar](64) NOT NULL,
163 PRIMARY KEY CLUSTERED
164(
165 [UUID] ASC
166)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
167) ON [PRIMARY]
168
169
170CREATE NONCLUSTERED INDEX [session] ON [agents]
171(
172 [sessionID] ASC
173)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
174
175CREATE NONCLUSTERED INDEX [ssession] ON [agents]
176(
177 [secureSessionID] ASC
178)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
179
180
181CREATE TABLE [dbo].[userfriends](
182 [ownerID] [varchar](50) COLLATE Latin1_General_CI_AS NOT NULL,
183 [friendID] [varchar](50) COLLATE Latin1_General_CI_AS NOT NULL,
184 [friendPerms] [nvarchar](50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
185 [datetimestamp] [nvarchar](50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
186) ON [PRIMARY]
187
188CREATE TABLE [avatarappearance] (
189 [Owner] [varchar](36) NOT NULL,
190 [Serial] int NOT NULL,
191 [Visual_Params] [image] NOT NULL,
192 [Texture] [image] NOT NULL,
193 [Avatar_Height] float NOT NULL,
194 [Body_Item] [varchar](36) NOT NULL,
195 [Body_Asset] [varchar](36) NOT NULL,
196 [Skin_Item] [varchar](36) NOT NULL,
197 [Skin_Asset] [varchar](36) NOT NULL,
198 [Hair_Item] [varchar](36) NOT NULL,
199 [Hair_Asset] [varchar](36) NOT NULL,
200 [Eyes_Item] [varchar](36) NOT NULL,
201 [Eyes_Asset] [varchar](36) NOT NULL,
202 [Shirt_Item] [varchar](36) NOT NULL,
203 [Shirt_Asset] [varchar](36) NOT NULL,
204 [Pants_Item] [varchar](36) NOT NULL,
205 [Pants_Asset] [varchar](36) NOT NULL,
206 [Shoes_Item] [varchar](36) NOT NULL,
207 [Shoes_Asset] [varchar](36) NOT NULL,
208 [Socks_Item] [varchar](36) NOT NULL,
209 [Socks_Asset] [varchar](36) NOT NULL,
210 [Jacket_Item] [varchar](36) NOT NULL,
211 [Jacket_Asset] [varchar](36) NOT NULL,
212 [Gloves_Item] [varchar](36) NOT NULL,
213 [Gloves_Asset] [varchar](36) NOT NULL,
214 [Undershirt_Item] [varchar](36) NOT NULL,
215 [Undershirt_Asset] [varchar](36) NOT NULL,
216 [Underpants_Item] [varchar](36) NOT NULL,
217 [Underpants_Asset] [varchar](36) NOT NULL,
218 [Skirt_Item] [varchar](36) NOT NULL,
219 [Skirt_Asset] [varchar](36) NOT NULL,
220
221 PRIMARY KEY CLUSTERED (
222 [Owner]
223 ) WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
224) ON [PRIMARY]