Last modified: 2013-01-25 21:49:48 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T13057, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 11057 - Increase size of ug_group in user_groups table
Increase size of ug_group in user_groups table
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
Database (Other open bugs)
unspecified
All All
: Low enhancement (vote)
: ---
Assigned To: Sam Reed (reedy)
: schema-change
Depends on:
Blocks: 15285
  Show dependency treegraph
 
Reported: 2007-08-24 18:41 UTC by Ryan Lane
Modified: 2013-01-25 21:49 UTC (History)
8 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Ryan Lane 2007-08-24 18:41:52 UTC
The current size of ug_group is 16. When synchronizing groups from external sources, this causes some issues.

Can the size be increased to 64? This is the maximum group name size in Active Directory, and it is unlikely that we'll run into groups with a name that long anywhere else (where the maximum is 256).
Comment 1 Aryeh Gregor (not reading bugmail, please e-mail directly) 2007-08-24 18:45:37 UTC
Does VARCHAR(255) actually take up any more storage space than VARCHAR(16), given identical records?  If not, we may as well make it 255 characters.
Comment 2 Chad H. 2009-07-01 13:31:03 UTC
It shouldn't. Don't see any compelling reason not to increase it to 255.
Comment 3 Chris 2009-08-18 18:43:57 UTC
Definitely causes Active Directory Authentication headaches. It should be a simply query fix in wikiTables.sql from char(16) to varchar(255) when creating the initial tables and an update script of 

<code>alter table user_groups change ug_group ug_group varchar(255)</code>

Of course if there are any other databases to use then there would need to be some translation.

Comment 4 Aryeh Gregor (not reading bugmail, please e-mail directly) 2010-03-25 13:53:20 UTC
Domas, is this possible, or would it cause problems?
Comment 5 Sam Reed (reedy) 2012-02-09 22:42:03 UTC
I made it upto 32 characters for 1.19
Comment 6 Ryan Lane 2012-02-10 04:18:48 UTC
Why 32, rather than 255, or at least 64, which I originally asked for? 32 still doesn't address the stated problem.
Comment 7 Sam Reed (reedy) 2012-02-10 18:30:43 UTC
(In reply to comment #6)
> Why 32, rather than 255, or at least 64, which I originally asked for? 32 still
> doesn't address the stated problem.

I didn't know there were any requests to make it larger still...

It is easily enough fixed though
Comment 8 Phillip Hagerman 2013-01-02 17:11:32 UTC
This is still 32 in 1.20.2 will it be addressed in the next release?

As it is now I have to remove the now-invalidated user group names and alter the table manually

ALTER TABLE `ABCXYZ_user_groups` CHANGE `ug_group` `ug_group` VARBINARY(255) NOT NULL DEFAULT ''
Comment 9 Ryan Lane 2013-01-02 19:43:05 UTC
Let's make this 255 as a few people have suggested.
Comment 10 Sam Reed (reedy) 2013-01-02 20:24:15 UTC
https://gerrit.wikimedia.org/r/#/c/41983/
Comment 11 Umherirrender 2013-01-25 21:49:48 UTC
The gerrit change is already successfully merged

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links