Get a list of field attributes for specific screens.

I would like to get a list of the attributes for the fields in my JIRA project and issue fields so that I can define mapping for integration from JIRA into and out-of an external data source.  Does anyone know how to get that information? 

Thank you so much for your insights!

2 answers

1 accepted

I found an Atlassian site that provided high-level information to meet my needs for now.  The following link accesses Atlassian "database" information without requiring programming.  It also provides SQL queries to get the info if you have access to the JIRA database.  I hope it is helpful to other non-programmers out there!

https://developer.atlassian.com/server/jira/platform/database-issue-fields/

Thank you for your help!

Pauletta

0 vote
Alexey Matveev Community Champion Jan 24, 2018

Hello,

What do you mean by "the attributes for the fields"? If you want to find issue fields you need to check the create, edit and view screens and also screens which are used in workflows for your project. It is a good practice (at least for me) to add a prefix with the project key to all screens which are used in the project.

Hi Alexey,  Thanks for responding.  I'm sorry my question wasn't clear. I am trying to find a way to get a list of the fields in my issue screen.  I want the list to also include information about the attributes of the fields such as data type, field length, requires or not required, default value, valid field values (for picklist fields), etc.  Are you aware of any way to get this type of list in JIRA?  Thank you for your insights!

Pauletta

Alexey Matveev Community Champion Jan 26, 2018

Do you want to get this info automatically? If yes then you would need to write a program using Jira Java Api. For example this program in groovy would iterate over all screens and get info about all custom fields.

import com.atlassian.jira.component.ComponentAccessor
ComponentAccessor.getFieldScreenManager().getFieldScreens().each{
    it.getTabs().each {  tab ->
        tab.getFieldScreenLayoutItems().each { fsl ->
            log.error(fsl.getFieldId())
            def cf = ComponentAccessor.getCustomFieldManager().getCustomFieldObject(fsl.getFieldId())
            if (cf != null)
             log.error(cf.getName() + " " + cf.getCustomFieldType().getKey());
        }
    }
}

I am sorry, Alexey; I'm not a programmer.  I don't even know where I would go to enter the code you listed above.  I was hoping to find-out that JIRA provides a user-friendly utility that I could use to generate a schema list for my Issues screens.  Based on your response and my research, it seems that a field schema list generator utility does not exist in JIRA.

I'm sorry to ask a very basic question but will you please tell me where I should enter the code you've provided above? 

Also, I actually need a field schema list for all fields (standard and custom) in my Issues screen.  Will you modify the query to give me a list of all fields in my Issues screen and attributes information about each fields (such as data type, field length, requires or not required, default value, valid field values (for picklist fields), etc). 

Thank you for your patience with a non-programmer who is assigned to do programming tasks at work!

Pauletta

Alexey Matveev Community Champion Jan 27, 2018

I do not know of such a plugin which would let you get the information that you need. But you can get it by using Jira GUI.

Thank you for your insights, Alexey. I will follow-up to try to use Jira GUI.  I appreciate you taking the time to respond to my question!  I hope you have a wonderful weekend. 

Pauletta

Thanks again for taking the time to respond to my question, Alexey.  You've inspired me to expand my knowledge of Jira GUI which will help me a lot going forward.  Your generosity with your knowledge is admirable.  Please continue to help me and others.  You are one of only a few who will take the time to do it!  You are appreciated.

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 Thursday in Confluence

Three common content challenges + how to manage them

An efficient enterprise content management system, or ECM, is a must-have for companies that create work online (cough   cough, all companies). If content calendars, marketing plans, and bu...

86 views 0 6
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