How to Re-order Statuses in Jira for Custom Workflows
Platform Notice: Data Center Only - This article only applies to Atlassian products on the Data Center platform.
Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Summary
⚠️ This is now available in the JIRA User Interface as of JIRA 6.3.8, as JRASERVER-5189 - Define status order has been implemented.
Before the release of JIRA 6.3.8, there was no way to change the Statuses order in JIRA.
Solution
Always back up your data before performing any modifications to the database. If possible, test any alter, insert, update, or delete SQL commands on a staging server first.
Credit for this workaround goes to the comment contributors on JRASERVER-5189 - Define status order.
Shut down JIRA
Backup Database
List down the current Statuses order using query below:
SELECT pname,SEQUENCE FROM issuestatus order by SEQUENCE;
The result from that query would be something like this:
pname | SEQUENCE |
Open | 1 |
In Progress | 2 |
Reopened | 3 |
Resolved | 4 |
Closed | 5 |
Update the current status sequence numbers to 10, 20, 30 instead of 1,2,3 so it's easier to modify later.
update issuestatus set SEQUENCE = 10 where SEQUENCE = 1;
Repeat step above for other statuses, you will get a result something like this:
pname | SEQUENCE |
Open | 10 |
In Progress | 20 |
Reopened | 30 |
Resolved | 40 |
Closed | 50 |
Finally, Update the table with the sequence you want, for example change Status "Reopened" show after status "Resolved":
update issuestatus set SEQUENCE = 45 where pname = "Reopened";
Restart or Re-index JIRA to take effect.
Was this helpful?