JQL Query Matches Condition
Use the JQL Query Matches Condition to control if an issue can be transitioned based on if a JQL query would return the current issue.
For example:
- If you want the transition to be allowed when the current issue is using the Task issue type, you would use the JQL query:
issuetype = "Task" - If you want the transition to be allowed when the current issue has a Priority of Medium or higher, you would use the JQL query:
priority >= Medium
Use this condition
You can add this condition to any transition except the Create transition.
Testing your JQL
You can use the Preview feature within the workflow condition to test your JQL query against a specific issue.
- Edit or create a new JQL query matches condition.
- Enter your JQL Query.
- Enter the key for an issue you want to test with into Preview Issue Key.
- Click Preview.
Note: This conditions JQL is efficient; for example if the query you enter would typically return millions of issues, it will be modified to something like the following:
{issue = 15130} AND {issuetype = "Task"}