Manual:MigrateUserGroup.php/fr

Détails
Le fichier 'migrateUserGroup.phpest un script de maintenance pour déplacer tous les utilisateurs appartenant à un groupe vers un autre. Ce script est par exemple utile si vous avez renommé un groupe d'utilisateurs dans LocalSettings.php et vous voulez que les utilisateurs de ce groupe restent dedans après le renommement. Un autre usage est quand vous voulez sortir tous les membres d'un groupe.

Should a member of the old group also already be a member of the new group, the script takes care to remove the old group from their user account.

Only works on explicit user groups, meaning on those groups, which are actually stored in the table inside the database. Does not work with implicit groups like "*" or "user", which are not stored in the table. This means the script currently cannot be used to e.g. add all users from the "user" group to another group.

Exemple
You had a group called "ninja" with some group rights set up, e.g.. Now you want to move all users from that group to the group named "peaceful-ninja":



Obtenir les clés 'perdues'
If you don't know the names of old groups that are preventing users from joining a renamed group, you can see all assigned groups by looking into the database table  in your database. The column  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:

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

