I need to rename a lot of groups.

Jens Knobloch June 15, 2015

Hi,

I need to rename the group names in JIRA, because of our company name was changed.

I searched and found several questions for it (i.e. https://answers.atlassian.com/questions/98523).
However, I would ask for a workaround to solve this despite of the fact, that many questions were responded with anwers like 'no way'.

So, can I rename the group name with (a) smart SQL statement(s)?
Which tables would be involved?
Why is such a common maintenance task so tricky, obviously?

thanks & best regards,

Jens.

2 answers

1 accepted

2 votes
Answer accepted
Joe Pitt
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
June 15, 2015

I'm not familiar with smart sql, but everyone is saying it is a bad idea because of how JIRA stores information. The safest way to modify the database is to disable logons for users, use the export to XML, edit the XML and save to a new name, import the edited file, stop/start the JIRA service, and then enable logons for users. However if your database is very large this can take a long time to export/import. Updating the database with sql often leads to problems because you miss something. If you want to try shut down JIRA and reindex after starting it back up.

1 vote
Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
June 15, 2015

The problem is that because JIRA supports many types of user directory, it has a very simple approach to groups - it uses the group name as the key. It used to do this with users too, until VERY recently (logon = key in that case), and it's a nightmare to refactor the whole system to use a key instead of the group name.

That's why you can't rename them - the name is the key, so you need to go through *everywhere* the name *might* have been used to check and update it.

Off the top of my head, you *might* have used a group name in

  • Project notifications
  • Permissions
  • Roles in projects (ok, I'm certain you've done this one)
  • Group pickers
  • JQL
  • Gadget definitions
  • Report, board, dashboard and filter shares
  • Workflow functions (stored as xml, NOT in discrete fields, so you can't search and replace SQL, you need a full blown xpath editor)
  • As for addons, well, you're on your own there - that's a complete free-for-all. If you've got Tempo or one of the other big ones that uses groups, you'll have to work out all their storage etc yourself.


I'm afraid you've been lumbered with a potentially vast painful job here, and SQL simply isn't the answer unless you can establish exactly how they've been used.

Your only option really is what Joe said (as I typed this up...)

Suggest an answer

Log in or Sign up to answer