Is there a way to have two custom fields associated to one another?

I am trying to have a custom field on my issue types, where based on its filled value, another custom field be automatically field.

e.g. If the custom field no.1 is a list of 'Colours', and custom field no.2 is a list of 'Fruits'. Once Red has been selected from 'Colours', then 'Fruits' should automatically be selected as Strawberry.

Is this possible at all?

5 answers

Thanks for the tips everyone!

I don't imagine these options are available for the OnDeman version though, am I correct?

We are using Database Custom Field in download version. I don t know if it s available for OnDemand version. Maybe you can ask the vendor.

Hi there,

I think everyone's suggestions are very good but perhaps a little eager and they have missed you are in onDemand. Unfortunately it means none of them will work.

You could try injecting some javascript into the description of the first field that updates the value of the second field while you are on the edit screen. It's not supported by Atlassian and it doesn't work if the user has disabled javascript or is using a remote API but it might help

Here is an example relating to AoD and injecting JS into the field description

https://confluence.atlassian.com/display/AOD/Creating+Help+for+a+Custom+Field

and some other helpful pages

https://answers.atlassian.com/questions/27160/how-do-you-embed-javascript-for-a-custom-field-in-jira-5-x

https://confluence.atlassian.com/display/JIRACOM/Using+JavaScript+to+Set+Custom+Field+Values

This is brilliant - thanks Matthew!

Take a look at Jamies behaviours plugin:

https://jamieechlin.atlassian.net/wiki/display/JBHV/JIRA+Behaviours+Plugin

You'll also find examples...

0 votes
Timothy Chin Community Champion May 28, 2013

The closest solution for this is to have a javascript manipulat the DOM. You can find some examples searching through here.

Hi!!

Maybe you can use Database Custom Field (https://marketplace.atlassian.com/plugins/com.keplerrominfo.jira.plugins.databasecf) and a auxiliar database table with the relationship between your fields.

Each field queries can be configured to depend on other fields.

So you ll have a table like this:

Color    Fruit
------- --------
Orange   Orange
Red      Strawberry
Yellow   Banana
...      ...

And 2 queries, one for each field like these:

Select Color
from table
Select fruit
from table
where color=customfieldX

Hope this helps.

Thank you Mario! Would I be able to use a Database cutom file on the OnDemand version of JIRA too, or is this only available on the hosted version?

We are using Database Custom Field in download version. I don t know if it s available for OnDemand version. Maybe you can ask the vendor.

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,795 views 11 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