Index: branches/5.2.x/core/install/install_schema.sql
===================================================================
diff -u -r14994 -r15012
--- branches/5.2.x/core/install/install_schema.sql	(.../install_schema.sql)	(revision 14994)
+++ branches/5.2.x/core/install/install_schema.sql	(.../install_schema.sql)	(revision 15012)
@@ -1,4 +1,4 @@
-CREATE TABLE PermissionConfig (
+CREATE TABLE CategoryPermissionsConfig (
   PermissionConfigId int(11) NOT NULL auto_increment,
   PermissionName varchar(255) NOT NULL default '',
   Description varchar(255) NOT NULL default '',
@@ -19,7 +19,7 @@
   UNIQUE KEY PermIndex (Permission,GroupId,CatId,`Type`)
 );
 
-CREATE TABLE CustomField (
+CREATE TABLE CustomFields (
   CustomFieldId int(11) NOT NULL auto_increment,
   `Type` int(11) NOT NULL default '0',
   FieldName varchar(255) NOT NULL default '',
@@ -43,7 +43,7 @@
   KEY DefaultValue (DefaultValue)
 );
 
-CREATE TABLE ConfigurationValues (
+CREATE TABLE SystemSettings (
   VariableId int(11) NOT NULL AUTO_INCREMENT,
   VariableName varchar(255) NOT NULL DEFAULT '',
   VariableValue text,
@@ -83,7 +83,7 @@
   KEY MailingId (MailingId)
 );
 
-CREATE TABLE Events (
+CREATE TABLE EmailEvents (
   EventId int(11) NOT NULL AUTO_INCREMENT,
   `Event` varchar(40) NOT NULL DEFAULT '',
   ReplacementTags text,
@@ -128,7 +128,7 @@
   lastid int(11) default NULL
 );
 
-CREATE TABLE Language (
+CREATE TABLE Languages (
   LanguageId int(11) NOT NULL AUTO_INCREMENT,
   PackName varchar(40) NOT NULL DEFAULT '',
   LocalName varchar(40) NOT NULL DEFAULT '',
@@ -173,7 +173,7 @@
   KEY LoadOrder (LoadOrder)
 );
 
-CREATE TABLE PersistantSessionData (
+CREATE TABLE UserPersistentSessionData (
   VariableId bigint(20) NOT NULL AUTO_INCREMENT,
   PortalUserId int(11) NOT NULL DEFAULT '0',
   VariableName varchar(255) NOT NULL DEFAULT '',
@@ -183,7 +183,7 @@
   KEY VariableName (VariableName)
 );
 
-CREATE TABLE Phrase (
+CREATE TABLE LanguageLabels (
   PhraseId int(11) NOT NULL AUTO_INCREMENT,
   Phrase varchar(255) NOT NULL DEFAULT '',
   PhraseKey varchar(255) NOT NULL DEFAULT '',
@@ -225,7 +225,7 @@
   KEY StylesheetId (StylesheetId)
 );
 
-CREATE TABLE PortalGroup (
+CREATE TABLE UserGroups (
   GroupId int(11) NOT NULL AUTO_INCREMENT,
   `Name` varchar(255) NOT NULL DEFAULT '',
   Description varchar(255) DEFAULT NULL,
@@ -242,7 +242,7 @@
   KEY CreatedOn (CreatedOn)
 );
 
-CREATE TABLE PortalUser (
+CREATE TABLE Users (
   PortalUserId int(11) NOT NULL AUTO_INCREMENT,
   Username varchar(255) NOT NULL,
   `Password` varchar(255) DEFAULT 'd41d8cd98f00b204e9800998ecf8427e',
@@ -288,14 +288,14 @@
   KEY Username (Username)
 );
 
-CREATE TABLE PortalUserCustomData (
+CREATE TABLE UserCustomData (
   CustomDataId int(11) NOT NULL auto_increment,
   ResourceId int(10) unsigned NOT NULL default '0',
   KEY ResourceId (ResourceId),
   PRIMARY KEY  (CustomDataId)
 );
 
-CREATE TABLE SessionData (
+CREATE TABLE UserSessionData (
   SessionKey varchar(50) NOT NULL DEFAULT '',
   VariableName varchar(255) NOT NULL DEFAULT '',
   VariableValue longtext,
@@ -304,7 +304,7 @@
   KEY VariableName (VariableName)
 );
 
-CREATE TABLE Theme (
+CREATE TABLE Themes (
   ThemeId int(11) NOT NULL AUTO_INCREMENT,
   `Name` varchar(40) NOT NULL DEFAULT '',
   Enabled int(11) NOT NULL DEFAULT '1',
@@ -339,7 +339,7 @@
   KEY TemplateAlias (TemplateAlias)
 );
 
-CREATE TABLE UserGroup (
+CREATE TABLE UserGroupRelations (
   PortalUserId int(11) NOT NULL DEFAULT '0',
   GroupId int(11) NOT NULL DEFAULT '0',
   MembershipExpires int(10) unsigned DEFAULT NULL,
@@ -350,7 +350,7 @@
   KEY ExpirationReminderSent (ExpirationReminderSent)
 );
 
-CREATE TABLE UserSession (
+CREATE TABLE UserSessions (
   SessionKey int(10) unsigned NOT NULL DEFAULT '0',
   LastAccessed int(10) unsigned NOT NULL DEFAULT '0',
   PortalUserId int(11) NOT NULL DEFAULT '-2',
@@ -380,7 +380,7 @@
   KEY `timestamp` (`timestamp`)
 );
 
-CREATE TABLE Cache (
+CREATE TABLE SystemCache (
   VarName varchar(255) NOT NULL default '',
   Data longtext,
   Cached int(11) default NULL,
@@ -406,7 +406,7 @@
   KEY l1_Name (l1_Name(5))
 );
 
-CREATE TABLE Category (
+CREATE TABLE Categories (
   CategoryId int(11) NOT NULL AUTO_INCREMENT,
   `Type` int(11) NOT NULL DEFAULT '1',
   SymLinkCategoryId int(10) unsigned DEFAULT NULL,
@@ -535,7 +535,7 @@
   KEY Filename (Filename)
 );
 
-CREATE TABLE PermCache (
+CREATE TABLE CategoryPermissionsCache (
   PermCacheId int(11) NOT NULL auto_increment,
   CategoryId int(11) NOT NULL default '0',
   PermId int(11) NOT NULL default '0',
@@ -571,7 +571,7 @@
   KEY LastCounted (LastCounted)
 );
 
-CREATE TABLE Skins (
+CREATE TABLE AdminSkins (
   SkinId int(11) NOT NULL AUTO_INCREMENT,
   `Name` varchar(255) DEFAULT NULL,
   CSS text,
@@ -607,7 +607,7 @@
   KEY MasterPrefix (MasterPrefix)
 );
 
-CREATE TABLE SessionLogs (
+CREATE TABLE UserSessionLogs (
   SessionLogId bigint(20) NOT NULL AUTO_INCREMENT,
   PortalUserId int(11) NOT NULL DEFAULT '0',
   SessionId int(10) NOT NULL DEFAULT '0',
@@ -727,7 +727,7 @@
   PRIMARY KEY (LocaleId)
 );
 
-CREATE TABLE BanRules (
+CREATE TABLE UserBanRules (
   RuleId int(11) NOT NULL auto_increment,
   RuleType tinyint(4) NOT NULL default '0',
   ItemField varchar(255) default NULL,
@@ -754,7 +754,7 @@
   PRIMARY KEY  (CountCacheId)
 );
 
-CREATE TABLE Favorites (
+CREATE TABLE UserFavorites (
   FavoriteId int(11) NOT NULL auto_increment,
   PortalUserId int(11) NOT NULL default '0',
   ResourceId int(11) NOT NULL default '0',
@@ -766,7 +766,7 @@
   KEY ItemTypeId (ItemTypeId)
 );
 
-CREATE TABLE Images (
+CREATE TABLE CatalogImages (
   ImageId int(11) NOT NULL auto_increment,
   ResourceId int(11) NOT NULL default '0',
   Url varchar(255) NOT NULL default '',
@@ -788,7 +788,7 @@
   KEY Priority (Priority)
 );
 
-CREATE TABLE ItemRating (
+CREATE TABLE CatalogRatings (
   RatingId int(11) NOT NULL auto_increment,
   IPAddress varchar(255) NOT NULL default '',
   CreatedOn INT UNSIGNED NULL DEFAULT NULL,
@@ -800,7 +800,7 @@
   KEY RatingValue (RatingValue)
 );
 
-CREATE TABLE ItemReview (
+CREATE TABLE CatalogReviews (
   ReviewId int(11) NOT NULL AUTO_INCREMENT,
   CreatedOn int(10) unsigned DEFAULT NULL,
   ReviewText longtext,
@@ -866,7 +866,7 @@
   KEY Module (Module)
 );
 
-CREATE TABLE ItemFiles (
+CREATE TABLE CatalogFiles (
   FileId int(11) NOT NULL AUTO_INCREMENT,
   ResourceId int(11) unsigned NOT NULL DEFAULT '0',
   FileName varchar(255) NOT NULL DEFAULT '',
@@ -882,7 +882,7 @@
   KEY `Status` (`Status`)
 );
 
-CREATE TABLE Relationship (
+CREATE TABLE CatalogRelationships (
   RelationshipId int(11) NOT NULL auto_increment,
   SourceId int(11) default NULL,
   TargetId int(11) default NULL,
@@ -929,7 +929,7 @@
   KEY CustomFieldId (CustomFieldId)
 );
 
-CREATE TABLE SearchLog (
+CREATE TABLE SearchLogs (
   SearchLogId int(11) NOT NULL auto_increment,
   Keyword varchar(255) NOT NULL default '',
   Indices bigint(20) NOT NULL default '0',
@@ -978,7 +978,7 @@
   KEY `Status` (`Status`)
 );
 
-CREATE TABLE Visits (
+CREATE TABLE UserVisits (
   VisitId int(11) NOT NULL AUTO_INCREMENT,
   VisitDate int(10) unsigned DEFAULT NULL,
   Referer varchar(255) NOT NULL DEFAULT '',
@@ -1001,7 +1001,7 @@
   KEY VarName (VarName)
 );
 
-CREATE TABLE RelatedSearches (
+CREATE TABLE CategoryRelatedSearches (
   RelatedSearchId int(11) NOT NULL auto_increment,
   ResourceId int(11) NOT NULL default '0',
   Keyword varchar(255) NOT NULL default '',
@@ -1122,7 +1122,7 @@
   KEY MessageId (MessageId)
 );
 
-CREATE TABLE SubmissionLog (
+CREATE TABLE FormSubmissionReplies (
   SubmissionLogId int(11) NOT NULL AUTO_INCREMENT,
   FormSubmissionId int(10) unsigned NOT NULL,
   FromEmail varchar(255) NOT NULL DEFAULT '',
@@ -1153,7 +1153,7 @@
   KEY MessageId (MessageId)
 );
 
-CREATE TABLE Drafts (
+CREATE TABLE FormSubmissionReplyDrafts (
   DraftId int(11) NOT NULL AUTO_INCREMENT,
   FormSubmissionId int(10) unsigned NOT NULL DEFAULT '0',
   CreatedOn int(10) unsigned DEFAULT NULL,
