Sorting on two fields one of which is the Rank field

Hi,

I am using JIRA + Greenhopper OnDemand. I am having a strange problem that I can't understand. Here is my setup:

2 projects: Imported and New. Imported was created out of an import from a CSV file and has a custom number field called custom_rank (its a relative number where the lower the number, the higher the priority). New was created as a new jira project. Global ranking is enabled.

My goal: Have a common backlog query across old and new projects which is sorted by priority. I want to do a primary sorting using the system Rank field in JIRA and a secondary sorting using the custom_rank field in the Imported project (since I do not want to lose the prioritization in the Imported project which is based on the custom rank).

Here is my overly simplified JQL:

status = Open ORDER BY Rank, custom_rank ASC

But this does not give my the desired results. The issues in the Imported project are not ranked at all by custom rank and are in an order that does not make sense. However when I do:

project = Imported AND status = Open ORDER BY custom_rank ASC

this works absolutely fine and I can see that my original prioritization by custom_rank is respected.

Is there a known issue when the Rank field is used along with a custom field in an order by clause? Could it be that the import wizard assigns random rank numbers to the imported issues and not the same rank to all of them?

Any help is greatly appreciated!

1 answer

1 accepted

0 votes
Timothy Chin Community Champion Jun 23, 2013

I want to do a primary sorting using the system Rank field in JIRA and a secondary sorting using the custom_rank field in the Imported project

You have a fundamental error here. It's impossible to sort your issues because your issues does not use the same field to sort against. You should either fill in all your issues with custom_rank or remove it and use the priority field.

Could it be that the import wizard assigns random rank numbers to the imported issues and not the same rank to all of them?

The numbers are not random and are not unique.

Suggest an answer

Log in or Join to answer
Community showcase
Sarah Schuster
Posted Jan 29, 2018 in Jira

What are common themes you've seen across successful & failed Jira Software implementations?

Hey everyone! My name is Sarah Schuster, and I'm a Customer Success Manager in Atlassian specializing in Jira Software Cloud. Over the next few weeks I will be posting discussion topics (8 total) to ...

2,968 views 12 18
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot