V2 Groups
From OpenSimulator
(Add convertion script to enable the Switch from flotsam to v" core groups) |
(added comparison between Flotsam and jOpenSim tables) |
||
Line 2: | Line 2: | ||
The below script helps, converting exsisting Flotsam Groups or jOpenSim Groups (which uses Flotsam anyway) to the new Groups. This ensures, that you dont loose any Group Information, when you want to Switch over. | The below script helps, converting exsisting Flotsam Groups or jOpenSim Groups (which uses Flotsam anyway) to the new Groups. This ensures, that you dont loose any Group Information, when you want to Switch over. | ||
+ | |||
+ | Differences between jOpenSim and Flotsam (the table names): | ||
+ | |||
+ | jos_opensim_groupactive = osagent | ||
+ | jos_opensim_group = osgroup | ||
+ | jos_opensim_groupinvite =osgroupinvite | ||
+ | jos_opensim_groupmembership = osgroupmembership | ||
+ | jos_opensim_groupnotice = osgroupnotice | ||
+ | jos_opensim_grouprolemembership = osgrouprolemembership | ||
+ | jos_opensim_grouprole = osrole | ||
The Script (Replace ROBUSTDB with your ROBUST database and FLOTSAMDB with your database, containing your jOpenSim or your Flotsam tables!): | The Script (Replace ROBUSTDB with your ROBUST database and FLOTSAMDB with your database, containing your jOpenSim or your Flotsam tables!): |
Revision as of 10:08, 12 September 2013
As of OpenSimulator 0.7.6 Diva implemented the V2 Groups, which are now part of OpenSimulator core. Using the new groups do not need to use any third Party modules any more.
The below script helps, converting exsisting Flotsam Groups or jOpenSim Groups (which uses Flotsam anyway) to the new Groups. This ensures, that you dont loose any Group Information, when you want to Switch over.
Differences between jOpenSim and Flotsam (the table names):
jos_opensim_groupactive = osagent jos_opensim_group = osgroup jos_opensim_groupinvite =osgroupinvite jos_opensim_groupmembership = osgroupmembership jos_opensim_groupnotice = osgroupnotice jos_opensim_grouprolemembership = osgrouprolemembership jos_opensim_grouprole = osrole
The Script (Replace ROBUSTDB with your ROBUST database and FLOTSAMDB with your database, containing your jOpenSim or your Flotsam tables!):
/* SQL script to convert group tables from Flotsam Groups (Group database) or jOpenSim (tables in Joomla Database) to new V2 groups, which are part of OpenSimulator core up from 0.7.6 branch*/ /* FlotSam Tables latest version from https://github.com/mcortez/flotsam/tree/master/flotsam/Servers/XmlRpcGroupsServer/ Commit-No.: 18275462c9*/ /* jOpenSim Version: 0.2.6.4*/ /*fill os_groups_groups in ROBUST database with values from jos_opensim_groups or FlotSam osgroup*/ INSERT INTO `ROBUSTDB`.`os_groups_groups` (GroupID, Name, Charter, InsigniaID, FounderID, MembershipFee, OpenEnrollment, ShowInList, AllowPublish, MaturePublish, OwnerRoleID) select GroupID, Name, Charter, InsigniaID, FounderID, MemberShipFee, OpenEnrollment, ShowInList, AllowPublish, MaturePublish, OwnerRoleID from `FLOTSAMDB`.jos_opensim_group; /*fill os_groups_invites in ROBUST database with values from jos_opensim_groupinvite or FlotSam osgroupinvite*/ INSERT INTO `ROBUSTDB`.`os_groups_invites` (InviteID, GroupID, RoleID, PrincipalID, TMStamp) SELECT InviteID, GroupID, RoleID, AgentID, TMStamp FROM `FLOTSAMDB`.jos_opensim_groupinvite; /*fill os_groups_membership in ROBUST database with values from jos_opensim_groupmembership or FlotSam osgroupmembership*/ INSERT INTO `ROBUSTDB`.`os_groups_membership` (GroupID, PrincipalID, SelectedRoleID, Contribution, ListInProfile, AcceptNotices) SELECT GroupID, AgentID, SelectedRoleID, Contribution, ListInProfile, AcceptNotices FROM `FLOTSAMDB`.jos_opensim_groupmembership; /*fill os_groups_notices in ROBUST database with values from jos_opensim_groupnotice or FlotSam osgroupnotice*/ INSERT INTO `ROBUSTDB`.`os_groups_notices` (GroupID, NoticeID, TMStamp, FromName, Subject, Message) SELECT GroupID, NoticeID, Timestamp, FromName, Subject, Message FROM `FLOTSAMDB`.jos_opensim_groupnotice; /*fill os_groups_principals in ROBUST database with values from jos_opensim_groupactive or FlotSam osagent*/ INSERT INTO `ROBUSTDB`.`os_groups_principals` (PrincipalID, ActiveGroupID) SELECT AgentID, ActiveGroupID FROM `FLOTSAMDB`.jos_opensim_groupactive; /*fill os_groups_rolemembership in ROBUST database with values from jos_opensim_grouprolemembership or FlotSam osgrouprolemembership*/ INSERT INTO opensim_robust_test.os_groups_rolemembership (GroupID, RoleID, PrincipalID) SELECT GroupID, RoleID, AgentID FROM `FLOTSAMDB`.jos_opensim_grouprolemembership; /*fill os_groups_roles in ROBUST database with values from jos_opensim_grouproles or FlotSam osrole*/ INSERT INTO opensim_robust_test.os_groups_roles (GroupID, RoleID, Name, Description, Title, Powers) SELECT GroupID, RoleID, Name, Description, Title, Powers FROM `FLOTSAMDB`.jos_opensim_grouprole; /*fill os_groups_roles in ROBUST database with values from jos_opensim_offlinemessages --> no corresponding table in FlotSam -- only applies to jOpenSim*/ INSERT INTO opensim_robust_test.im_offline (PrincipalID, Message, TMStamp) SELECT fromAgentID, Message, sent FROM `FLOTSAMDB`.jos_opensim_offlinemessages;