How do i get 'RANK' field directly in DATABASE, any sql can do this?

As subject. We found some OA table related to 'rank' in database, but we have no idea about the logic and relationship of those tables. Can someone help me?

6 answers

1 accepted

OK, it turns out that the Global Rank is held as a linked list, making evaluating specific "Global Rank Value" more difficult.

A bit more digging turned up this answer, which I will play with: https://answers.atlassian.com/questions/96142/how-to-get-sprint-issue-list-by-sql

0 vote
Ahmad Danial Atlassian Team Aug 29, 2013

Hey there, Yunfeng.

I believe that you are referring to the AO_60DB71_ISSUERANKING table here. As we can see from the structure:

  1. CUSTOM_FIELD represents the Rank custom field
  2. ID represents the rank of the issue
  3. ISSUE_ID represents the ID of the issue that has the respective rank
  4. NEXT_ID is the link to the next ID of issue that is related to the ISSUE

So, if you want the Rank of an issue, let's say the issue ID is 10004, it can be something like:

SELECT ID FROM AO_60DB71_ISSUERANKING where ISSUE_ID = '10004';

Hope this helps.

Warm regards,

Danial

Hi Danial,

Thanks a lot, but i was confused whether 'ID' is exactly the 'RANK' where i view in the issue view page. I'm afraid that the ID doesn't directly refer to the value of 'RANK'. So where can we get the exact value of rank for a specific issue in DATABASE.

Hello, any update?

Joe Wai Tye Atlassian Team Sep 08, 2013

Hi Yunfeng,

If I understand Danial correctly, then the 'ID' of the AO_60DB71_ISSUERANKING table is actually the 'RANK' of the issues. Take the SQL query that he has provided as an example :

SELECTID FROMAO_60DB71_ISSUERANKING whereISSUE_ID = '10004';

This query would return the 'RANK' of the issue that has the issue ID of '10004'. Hope this clears things up a bit :)

Hi Danial,

Thanks a lot, but i was confused whether 'ID' is exactly the 'RANK' where i view in the issue view page. I'm afraid that the ID doesn't directly refer to the value of 'RANK'. So where can we get the exact value of rank for a specific issue in DATABASE.

Sorry to open this old question again, but I am having the same problem.

For example, I have an issue ID 18892 corresponding to a key ABC-123.

If I use your SQL above I get a rank of 7944.

If I create a filter in JIRA and select to display the Rank column, the rank number shown for that issue is 849.

If I use SQL to see what issue ID has rank 849, it is not the issue ID that I'm looking for.

Any ideas?

Hello,

I have the same problem. Is there any solution for that problem?

I have opened a support ticket - I'll post any progress here.

Has there been any progress on the support ticket?

Thanks for your help:-)

Suggest an answer

Log in or Sign up to answer
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Published Monday in Jira Software

How large do you think Jira Software can grow?

Hi Atlassian Community! My name is Shana, and I’m on the Jira Software team. One of the many reasons this Community exists is to connect you to others on similar product journeys or with comparabl...

667 views 6 12
Read article

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