JQL extension for system fields

 

Extended JQL syntax for system fields

The "Custom JQL" mode and the JQL filtering functionality of Issue Matrix for Jira support an extended JQL syntax which allows filtering based on the values of the system fields of the current issue. Below is a list of all the supported system fields with examples on how to use them.

 

Affected version

Syntax

${currentIssue.affectedVersion}

Return value description

Comma-separated list of the ids of all affected versions by the current issue.

Return value example

10001, 10003

Examples

  • Find all issues with an affected version which is contained in the list of affected versions for the current issue

    affectedVersion IN (${currentIssue.affectedVersion})

     

  • Find all issues with affected version which is contained in the list of affected versions for the current issue as well as the issues with empty value for that field

    affectedVersion in (${currentIssue.affectedVersion}, EMPTY)

 

  • Find all issues with fix version which is contained in the list of affected versions for the current issue

 

Assignee

Syntax

Return value description

The username of the "assignee" user of the current issue surrounded by double quotes.

Return value example

"Admin Username"

Examples

  • Find all issues with the same assignee as the current issue assignee

     

  • Find all issues with reporter different than the current issue assignee

 

Category

Syntax

Return value description

The id of the project category for the project to which the current issue belongs.

Return value example

10001

Examples

  • Find all issues with the same category as the current issue category

 

Component

Syntax

Return value description

Comma-separated list of component IDs of the current issue.

Return value example

10015, 10022

Examples

  • Find all issues with a component in the current issue components

     

  • Find all issues with a component in the current issue components as well as all issues with empty value for that field

 

Created

Syntax

Return value description

The date when the current issue was created in the format "yyyy/MM/dd HH:mm" surrounded by double quotes.

Return value example

"2017/03/25 15:30"

Examples

  • Find all issues that were created after the creation date of the current issue

 

Creator

Syntax

Return value description

The username of the user who created the current issue surrounded by double quotes.

Return value example

"Admin Username"

Examples

  • Find all issues with the same assignee as the current issue creator



  • Find all issues with assignee that was the same as the current issue creator

 

Description

Syntax

Return value description

The description of the current issue surrounded by double quotes.

Return value example

"Some long description returned in double quotes"

Examples

  • Find all issues with summary not like the current issue description

 

Due Date

Syntax

Return value description

The due date of the current issue in the format "yyyy/MM/dd" surrounded by double quotes.

Return value example

"2017/03/25"

Examples

  • Find all issues that are due before the due date of the current issue

 

Environment

Syntax

Return value description

The environment of the current issue surrounded by double quotes.

Return value example

"Such a lovely environment does this issue have"

Examples

  • Find all issues with a description like the current issue environment

 

Fix version

Syntax

Return value description

Comma-separated list of the ids of all fix versions for the current issue.

Return value example

10001, 10005

Examples

  • Find all issues with fix version in current issue fix versions

     

  • Find all issues with fix version in current issue fix versions as well as all issues with empty value in that field

     

  • Find all issues with an affected version in current issue fix versions

 

Issue Key

Syntax

Return value description

Key of the current issue.

Return value example

HSP-225

Examples

  • Find all issues linked to the current issue.

 

Issue Type

Syntax

Return value description

Id of the issue type of the current issue

Return value example

10010

Examples

  • Find all issues with the same issue type as the current issue.

 

Labels

Syntax

Return value description

A comma-separated list of all the labels of the current issue.

Return value example

X, Y, Z

Examples

  • Find all issues having a common label with the current issue.

 

Level

Syntax

Return value description

The id of the security level of the current issue.

Return value example

10001

Examples

  • Find all issues having the same security level as the current issue.

 

Parent

Syntax

Return value description

The id of the parent issue.

Return value example

10001

Examples

  • Find all issues which have the same parent as the current issue.

 

Priority

Syntax

Return value description

The id of the priority of the current issue.

Return value example

10001

Examples

  • Find all issues which have the same priority as the current issue.

 

Project

Syntax

Return value description

The id of the current issue project.

Return value example

10001

Examples

  • Find all issues which are in the same project as the current issue.

 

Reporter

Syntax

Return value description

The username of the {fieldName} user who is the reporter of the current issue surrounded by double quotes.

Return value example

"Admin Username"

Examples

  • Find all issues with the same reporter as the current issue reporter



  • Find all issues with the assignee different from the current issue reporter

 

Resolution

Syntax

Return value description

Id of the resolution of the current issue.

Return value example

1

Examples

  • Find all issues which have the same resolution as the current issue.

 

Resolved

Syntax

Return value description

The resolution date of the current issue in the format "yyyy/MM/dd HH:mm" surrounded by double quotes.

Return value example

"2017/10/05 23:00"

Examples

  • Find all issues which were resolved before the current issue was resolved.

 

Status

Syntax

Return value description

Id of the status of the current issue.

Return value example

1

Examples

  • Find all issues which have the same status as the current issue.

 

Summary

Syntax

Return value description

The summary of the current issue surrounded by double quotes.

Return value example

"This is the issue summary"

Examples

  • Find all issues which have the same summary as the current issue.

 

Updated

Syntax

Return value description

The last update date of the current issue in the format "yyyy/MM/dd HH:mm" surrounded by double quotes.

Return value example

"2017/10/05 23:00"

Examples

  • Find all issues which were last updated before the current issue was last updated.

 

Voter

Syntax

Return value description

Comma-separated list of usernames of all the voters on the current issue.

Return value example

"James Jones", "Kate Hudson"

Examples

  • Find all issues with the same voters as the current issue.

 

Votes

Syntax

Return value description

Number of votes of the current issue.

Return value example

10

Examples

  • Find all issues with the same number of votes as the current issue.

 

Watcher

Syntax

Return value description

Comma-separated list of usernames of all the watchers of the current issue.

Return value example

"James Jones", "Kate Hudson"

Examples

  • Find all issues with the same watchers as the current issue.

 

Watchers

Syntax

Return value description

Number of watchers of the current issue.

Return value example

10

Examples

  • Find all issues with the same number of watchers as the current issue.

 

Sprint

Used in Jira Software only

Syntax

${currentIssue.sprint}

Return value description

Comma-separated list of sprint ids for the current issue

Return value example

1, 15

Examples

  • Find all issues assigned to the same sprints as the current issue:

 

  • Find all issues assigned to the same sprints as the current issue including the issues with empty value for that field:

 

  • Find all issues assigned to the same sprints as the current issue:

 

  • Find all issues assigned to the same sprints as the current issue:

 

Organizations

Used in Jira Service Management only

Syntax

${currentIssue.organizations}

Return value description

Comma-separated list of organizations' names surrounded by double quotes

Return value example

"Alpha", "Bravo", "Charlie"

Examples

  • Find all issues associated with the same organizations as in the current issue:

 

  • Find all issues associated with the same organizations as in the current issue including the issues with empty value for that field:

 

  • Find all issues associated with the same organizations as in the current issue:

 

  • Find all issues associated with the same organizations as in the current issue:

 

Customer Request Type

Used in Jira Service Management only

Syntax

${currentIssue.customerRequestType}

Return value description

Customer request type surrounded by double quotes

Return value example

"New employee"

Examples

  • Find all issues with the same "Customer Request Type" as the customer request type of the current issue:

"Customer Request Type" = ${currentIssue.customerRequestType}

 

  • Find all issues with the same "Customer Request Type" as the customer request type of the current issue:

    "Customer Request Type" = ${currentIssue.cf["Customer Request Type"]}

 

  • Find all issues with "Customer Request Type" the same as the customer request type with a specific id in the current issue:

"Customer Request Type" = ${currentIssue.cf[10001]}

Â