Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

How to make 'development[deployment].environment' work in JQL

Daniel Schaller
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
July 30, 2019

Hi,

I have a number of deployment projects with many deployment environments in each. 

I am trying to use JQL where I can find all issues that have not been deployed to a particular environment yet.

According to https://confluence.atlassian.com/jirasoftwareserver080/advanced-searching-development-fields-reference-973500667.html this should be possible using 'development[deployment].environment'.

However, whatever I am trying it won't work.

For example, let's say I have 5 PROD environments with a name all like 'PROD - ABC', 'PROD - DEF' and so one.

If I want to find all issues that have label 'abc' and have not been deployed to 'PROD - ABC' yet, I would run the following JQL:

label = abc AND development[deployment].environment != "PROD - ABC" 

However, I am getting all issues with label 'abc' no matter if they have already been deployed to "PROD - ABC" or not. 

If I change the query to 

label = abc AND development[deployment].environment = "PROD - ABC" 

meaning, I am looking for all issues with label 'abc' that have been deployed to "PROD - ABC", nothing is being returned at all, even issues that definitely have been deployed to this environment, which can be confirmed when looking through the list of environments you can check when clicking on the 'Deploy to....' link in the Development field section of an issue.

 

Any idea what I may be doing wrong or if this kind of query is possible at all?

 

 

Thanks,

Daniel

 

 

 

1 answer

0 votes
Brandon Groves
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
July 26, 2023

By chance have any of the linked Jira issues ever been deployed to an environment yet? I had to make a query that checked if no deployments existed or if they weren't in a particular environment.

Example:

... AND (development[deployments].all = 0 OR development[deployments].environment NOT IN ("PROD - ABC"))

Suggest an answer

Log in or Sign up to answer