Hello, I am looking for a query or filter to list all distinct values for a field called Domain (its a Dropbox) in a JIRA Project. Can someone help me?
Hello @Saraswathi Vepa ! Welcome to the Atlassian Community!
JQL queries won't get what you're looking for. You may want to do this using the REST API.
always like to see a REST API solution :-). Since these are GET calls, you can submit them in a browser. you might need three calls as follows:
1. Search fields based on the name. In your case you will use your URL and the term "Domain". These are all case sensitive so be sure to spell it correctly
https://splitdimedata.atlassian.net/rest/api/3/field/search?query=SDD
Results:
{ "maxResults": 50, "startAt": 0, "total": 1, "isLast": true, "values": [ { "id": "customfield_10067", "name": "SDD_Client", "schema": { "type": "array", "items": "option", "custom": "com.atlassian.jira.plugin.system.customfieldtypes:multicheckboxes", "customId": 10067 }, "description": "Client Impacted" } ] }
2. I used the custom id to get the valid contexts:
https://splitdimedata.atlassian.net/rest/api/3/field/customfield_10067/context
Results:
{ "maxResults": 50, "startAt": 0, "total": 1, "isLast": true, "values": [ { "id": "10184", "name": "Default Configuration Scheme for SDD_Client", "description": "Default configuration scheme generated by Jira", "isGlobalContext": true, "isAnyIssueType": true } ] }
Finally, the call mentioned by the person who provided the original answer:
https://splitdimedata.atlassian.net/rest/api/3/field/customfield_10067/context/10184/option
{ "maxResults": 100, "startAt": 0, "total": 4, "isLast": true, "values": [ { "id": "10048", "value": "Caterpillar (Fred)", "disabled": false }, { "id": "10049", "value": "Utility Client (Wilma)", "disabled": false }, { "id": "10050", "value": "Atlanta (Barney)", "disabled": false }, { "id": "10051", "value": "West Coast (Betty)", "disabled": false } ] }
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Although JQL lacks a built-in feature for directly listing different values, you can evaluate the results by filtering issues by a particular field:
Go to Advanced Issue Search under Filters.
Execute the following JQL query: project = "ProjectName" BUY USING "CustomField"
Export the results to a CSV file (if the list is long) and use a tool like Excel or Google Sheets to find distinct values.
Please accept the answer if you feel this as solution for you. Thanks
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Where did you get that JQL Query? That will not work.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Saraswathi - Welcome to the Atlassian Community!
When you say it is a dropbox field - do you mean drop down?
If so, just create a filter that shows all issues on the project - simple as Project = ABC. Save that filter.
Then create a dashboard or use an existing dashboard and add a gadget for Issue Statistics. Use the Domain field for the Statistic. This will show you all of the unique values.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Saraswathi Vepa ,
Welcome to Atlassian Community !!
As @Robert Wen_Cprime_ mentioned JQL itself doesn't have a built-in function for directly listing distinct values, but you can filter issues by a specific field and review the results:
project = "ProjectName" ORDER BY "CustomField"
Please accept the answer if you feel this as solution for you. Thanks!
Regards
RK
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.