1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-08-09 10:16:36 +02:00

Ok, it's that time again! Well, in preparation for the release of 2.0.2, I

have created the update file.  The update has a schema change in the
phpbb_groups table; the group id is now auto-increment.  This should solve
a problem in upgrade.php, as well as make some scripts a little more
efficient.  The update script will take care of the required changes, as
none of the PHP files mentioned above will work without the group_id set
as auto_increment.

That's all for now!
dougk_ff7


git-svn-id: file:///svn/phpbb/branches/phpBB-2_0_0@2796 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
dougk_ff7
2002-07-31 18:50:25 +00:00
parent 1a6592ff43
commit cf29f6bacc
5 changed files with 677 additions and 47 deletions

View File

@@ -494,19 +494,6 @@ if ( isset($HTTP_POST_VARS['submit']) )
}
$user_id = $row['total'] + 1;
$sql = "SELECT MAX(group_id) AS total
FROM " . GROUPS_TABLE;
if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, 'Could not obtain next user_id information', '', __LINE__, __FILE__, $sql);
}
if ( !($row = $db->sql_fetchrow($result)) )
{
message_die(GENERAL_ERROR, 'Could not obtain next user_id information', '', __LINE__, __FILE__, $sql);
}
$group_id = $row['total'] + 1;
//
// Get current date
//
@@ -530,12 +517,14 @@ if ( isset($HTTP_POST_VARS['submit']) )
message_die(GENERAL_ERROR, 'Could not insert data into users table', '', __LINE__, __FILE__, $sql);
}
$sql = "INSERT INTO " . GROUPS_TABLE . " (group_id, group_name, group_description, group_single_user, group_moderator)
VALUES ($group_id, '', 'Personal User', 1, 0)";
$sql = "INSERT INTO " . GROUPS_TABLE . " (group_name, group_description, group_single_user, group_moderator)
VALUES ('', 'Personal User', 1, 0)";
if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, 'Could not insert data into groups table', '', __LINE__, __FILE__, $sql);
}
$group_id = $db->sql_nextid();
$sql = "INSERT INTO " . USER_GROUP_TABLE . " (user_id, group_id, user_pending)
VALUES ($user_id, $group_id, 0)";