Thread:Project:Support desk/Whats the easiest way to get ' user group key ' (2)/reply

Hi!

The user group key is the name of the user group as it had been used in $wgGroupPermissions. E.g.

$wgGroupPermissions['ninja']['block'] = true;

will create a group with the group key "ninja". After you removed this group from LocalSettings.php, I am not sure, if it then is still displayed inside the MediaWiki interface. However, there is another fairly simple way of finding out the name:

You can see all assigned groups by looking into the database table user_groups in your database. The column ug_group will contain the user group key of the group, which a user is member of.

A bit more advanced would be to use DISTINCT in the SQL query like so:

SELECT DISTINCT ug_group FROM user_groups;

That will show you a list of all different values in that column - meaning: Each group will only be listed once, no matter how many members it actually has.