aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Data/PGSQL/Resources/os_groups_Store.migrations
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Data/PGSQL/Resources/os_groups_Store.migrations')
-rw-r--r--OpenSim/Data/PGSQL/Resources/os_groups_Store.migrations94
1 files changed, 94 insertions, 0 deletions
diff --git a/OpenSim/Data/PGSQL/Resources/os_groups_Store.migrations b/OpenSim/Data/PGSQL/Resources/os_groups_Store.migrations
new file mode 100644
index 0000000..4573f71
--- /dev/null
+++ b/OpenSim/Data/PGSQL/Resources/os_groups_Store.migrations
@@ -0,0 +1,94 @@
1:VERSION 1 # --------------------------
2
3BEGIN;
4
5CREATE TABLE os_groups_groups (
6 "GroupID" char(36) Primary Key NOT NULL default '',
7 "Location" varchar(255) NOT NULL default '',
8 "Name" varchar(255) NOT NULL default '',
9 "Charter" text NOT NULL,
10 "InsigniaID" char(36) NOT NULL default '',
11 "FounderID" char(36) NOT NULL default '',
12 "MembershipFee" integer NOT NULL default '0',
13 "OpenEnrollment" varchar(255) NOT NULL default '',
14 "ShowInList" integer NOT NULL default '0',
15 "AllowPublish" integer NOT NULL default '0',
16 "MaturePublish" integer NOT NULL default '0',
17 "OwnerRoleID" char(36) NOT NULL default ''
18);
19
20
21CREATE TABLE os_groups_membership (
22 "GroupID"char(36) NOT NULL default '',
23 "PrincipalID" VARCHAR(255) NOT NULL default '',
24 "SelectedRoleID" char(36) NOT NULL default '',
25 "Contribution" integer NOT NULL default '0',
26 "ListInProfile" integer NOT NULL default '1',
27 "AcceptNotices" integer NOT NULL default '1',
28 "AccessToken" char(36) NOT NULL default '',
29 constraint os_groupmemberpk primary key ("GroupID", "PrincipalID")
30);
31
32
33
34CREATE TABLE os_groups_roles (
35 "GroupID" char(36) NOT NULL default '',
36 "RoleID" char(36) NOT NULL default '',
37 "Name" varchar(255) NOT NULL default '',
38 "Description" varchar(255) NOT NULL default '',
39 "Title" varchar(255) NOT NULL default '',
40 "Powers" bigint NOT NULL default 0,
41 constraint os_grouprolepk PRIMARY KEY ("GroupID","RoleID")
42);
43
44
45CREATE TABLE os_groups_rolemembership (
46 "GroupID" char(36) NOT NULL default '',
47 "RoleID" char(36) NOT NULL default '',
48 "PrincipalID" VARCHAR(255) NOT NULL default '',
49 constraint os_grouprolememberpk PRIMARY KEY ("GroupID","RoleID","PrincipalID")
50);
51
52
53CREATE TABLE os_groups_invites (
54 "InviteID" char(36) NOT NULL default '',
55 "GroupID" char(36) NOT NULL default '',
56 "RoleID" char(36) NOT NULL default '',
57 "PrincipalID" VARCHAR(255) NOT NULL default '',
58 "TMStamp" timestamp NOT NULL default now(),
59 constraint os_groupinvitespk PRIMARY KEY ("InviteID")
60);
61-- UNIQUE KEY "PrincipalGroup" ("GroupID","PrincipalID")
62
63
64CREATE TABLE os_groups_notices (
65 "GroupID" char(36) NOT NULL default '',
66 "NoticeID" char(36) NOT NULL default '',
67 "TMStamp" integer NOT NULL default '0',
68 "FromName" varchar(255) NOT NULL default '',
69 "Subject" varchar(255) NOT NULL default '',
70 "Message" text NOT NULL,
71 "HasAttachment" integer NOT NULL default '0',
72 "AttachmentType" integer NOT NULL default '0',
73 "AttachmentName" varchar(128) NOT NULL default '',
74 "AttachmentItemID" char(36) NOT NULL default '',
75 "AttachmentOwnerID" varchar(255) NOT NULL default '',
76 constraint os_groupsnoticespk PRIMARY KEY ("NoticeID")
77);
78-- KEY "GroupID" ("GroupID"),
79-- KEY "TMStamp" ("TMStamp")
80
81CREATE TABLE os_groups_principals (
82 "PrincipalID" VARCHAR(255) NOT NULL default '',
83 "ActiveGroupID" char(36) NOT NULL default '',
84 constraint os_groupprincpk PRIMARY KEY ("PrincipalID")
85);
86
87COMMIT;
88
89:VERSION 2 # --------------------------
90
91BEGIN;
92
93
94COMMIT;