How do you create a read-only custom feild that generates a unique ID whenever an issue is created (Jira Cloud)

Can anyone provide me with a quick solution? I really need a unique issue ID other than the one generated per project on Jira.

2 answers

0 votes

What's wrong with the JIRA issue ID? 

Not that it matters - you'll need code to do it, which you can't really do on Cloud.  A Connect add on might be able to provide something to stick on an issue, but it won't be ideal (i.e. not quite a field).  Even if you did do this, you'd want to generate something based on the, well, JIRA issue ID, otherwise you can't guarantee uniqueness.

Having an issue ID tied to a project is fine. I need a supplemental issue ID that will be static from the moment it is created such that if the issue is moved to a different project that issue ID is not changed. Our company uses these IDs for reference documents that may be released to customers and we definitely do not want project IDs included in that document. Furthermore, we definitely do not want to manually create the issue IDs by hand or map them ourselves. JIRA should have a way to create a project independent issue ID.

For this case, I'd simply try to expose the issue ID in the database, rather than the issue Key.  The id of an issue doesn't change when you move it.  But again, I'm not sure you can usefully expose that in the UI on Cloud.

But you could still use the JIRA Key, even though it can change when an issue moves projects, JIRA remembers that.  If you have ABC-123 and move it to DEF-456, then you go visit https://yourjira/browse/ABC-123, it will take you to DEF-456.

(One other random thought is also "turn off the right to move issues", but that feels inflexible)

Thanks - that bit of information might be enough for us! It would be good if that unique key (independent of project) was exposed to cloud users somehow.

Do we have a solution for this issue in JIRA Cloud yet??

I'd use Script Runner for JIRA Cloud to write a post-function for the create transition that takes the issue id from the database and copies it out to a custom text field that is only put on "issue view" screens.

I certainly wouldn't try to generate your own sequence either - the issue id in the database is the only safe reliable way to do this without masses of complex code.

I'm still not sure it's of any real use when the issue key is what the humans use and has all the functionality.

 

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Sep 18, 2018 in Jira

What modern development practices are at the heart of how your team delivers software?

Hey Community mates! Claire here from the Software Product Marketing team. We all know software development changes rapidly, and it's often tough to keep up. But from our research, we've found the h...

24,624 views 2 7
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