• Products
  • Get started
  • Documentation
  • Resources

JQL operators

This page describes information about operators that are used for advanced searching.

An operator in JQL is one or more symbols or words, which compares the value of a field on its left with one or more values (or functions) on its right, such that only true results are retrieved by the clause. Some operators may use the NOT keyword.

Equals (=)

The "=" operator is used to search for issues where the value of the specified field exactly matches the specified value. (Note: cannot be used with text fields; see the CONTAINS operator instead.)

To find issues where the value of a specified field exactly matches multiple values, use multiple "=" statements with the AND operator.

Examples

  • Find all issues that were created by John Smith:

    1 reporter = "John Smith"
  • Find all issues that were created by John Smith whose Atlassian account id is abcde-12345-fedcba:

    1 reporter = "abcde-12345-fedcba"

Not equals (!=)

The "!=" operator is used to search for issues where the value of the specified field does not match the specified value. (Note: cannot be used with text fields; see the DOES NOT MATCH ("!~") operator instead.)

Note that typing field != value is the same as typing NOT field = value, and that field != EMPTY is the same as field IS_NOT EMPTY.

The "!=" operator will not match a field that has no value (i.e. a field that is empty). For example, component != fred will only match issues that have a component and the component is not "fred". To find issues that have a component other than "fred" or have no component, you would need to type: component != fred or component is empty.

Examples

  • Find all issues that are assigned to any user's Atlassian account id except John Smith's:

    1 not assignee = abcde-12345-fedcba

    or

    1 assignee != abcde-12345-fedcba
  • Find all issues that are not assigned to John Smith's Atlassian account ID

    1 assignee != abcde-12345-fedcba or assignee is empty
  • Find all issues that were reported by me but are not assigned to me:

    1 reporter = currentUser() and assignee != currentUser()
  • Find all issues where the Reporter or Assignee is anyone except John Smith:

    1 assignee != "John Smith" or reporter != "John Smith"
  • Find all issues where the Reports or Assignee is anyone except John Smith's:

    1 assignee != "John Smith" or reporter != "John Smith"
  • Find all issues that are not unassigned:

    1 assignee is not empty

    or

    1 assignee != null

Greater than (>)

The ">" operator is used to search for issues where the value of the specified field is greater than the specified value.

Note that the ">" operator can only be used with fields that support ordering (e.g. date fields and version fields), and cannot be used with text fields. To see a field's supported operators, check the individual field reference.

Examples

  • Find all issues with more than 4 votes:

    1 votes > 4
  • Find all overdue issues:

    1 duedate < now() and resolution is empty
  • Find all issues where priority is higher than "Normal":

    1 priority > normal

Greater than equals (>=)

The ">=" operator is used to search for issues where the value of the specified field is greater than or equal to the specified value.

Note that the ">=" operator can only be used with fields that support ordering (e.g. date fields and version fields), and cannot be used with text fields. To see a field's supported operators, check the individual field reference.

Examples

  • Find all issues with 4 or more votes:

    1 votes >= 4
  • Find all issues due on or after 31/12/2008:

    1 duedate >= "2008/12/31"
  • Find all issues created in the last five days:

    1 created >= "-5d"

Less than (<)

The "<" operator is used to search for issues where the value of the specified field is less than the specified value.

Note that the "<" operator can only be used with fields which support ordering (e.g. date fields and version fields), and cannot be used with text fields. To see a field's supported operators, check the individual field reference.

Examples

  • Find all issues with less than 4 votes:

    1 votes < 4

Less than equals (<=)

The "<=" operator is used to search for issues where the value of the specified field is less than or equal to than the specified value.

Note that the "<=" operator can only be used with fields which support ordering (e.g. date fields and version fields), and cannot be used with text fields. To see a field's supported operators, check the individual field reference.

Examples

  • Find all issues with 4 or fewer votes:

    1 votes <= 4
  • Find all issues that have not been updated in the past month (30 days):

    1 updated <= "-4w 2d"

IN

The "IN" operator is used to search for issues where the value of the specified field is one of multiple specified values. The values are specified as a comma-delimited list, surrounded by parentheses.

Using "IN" is equivalent to using multiple EQUALS (=) statements, but is shorter and more convenient. That is, typing reporter IN (tom, jane, harry) is the same as typing reporter = "tom" OR reporter = "jane" OR reporter = "harry".

Examples

  • Find all issues that were created by either jsmith or jbrown or jjones:

    1 reporter in (jsmith,jbrown,jjones)
  • Find all issues that were created by John Smith, Jim Brown, or Jared Jones whose Atlassian account IDs are abcde-12345-fedcba or fedcb-12345-edcba or cdefb-67895-cbaed, respectively:

    1 reporter in (abcde-12345-fedcba,fedcb-12345-edcba,cdefb-67895-cbaed)
  • Find all issues where the Reporter or Assignee is either Jack or Jill:

    1 reporter in (Jack,Jill) or assignee in (Jack,Jill)
  • Find all issues where the Reporter or Assignee is either Jack or Jill whose Atlassian account IDs are abcde-12345-fedcba and cdefb-67895-cbaed, respectively:

    1 reporter in (abcde-12345-fedcba,cdefb-67895-cbaed) or assignee in (abcde-12345-fedcba,cdefb-67895-cbaed)
  • Find all issues in version 3.14 or version 4.2:

    1 affectedVersion in ("3.14", "4.2")

NOT IN

The "NOT IN" operator is used to search for issues where the value of the specified field is not one of multiple specified values.

Using "NOT IN" is equivalent to using multiple NOT_EQUALS (!=) statements, but is shorter and more convenient. That is, typing reporter NOT IN (tom, jane, harry) is the same as typing reporter != "tom" AND reporter != "jane" AND reporter != "harry".

The "NOT IN" operator will not match a field that has no value (i.e. a field that is empty). For example, assignee not in (jack,jill) will only match issues that have an assignee and the assignee is not "jack" or "jill". To find issues that are assigned to someone other than "jack" or "jill" or are unassigned, you would need to type: assignee not in (jack,jill) or assignee is empty.

Examples

  • Find all issues where the Assignee is someone other than Jack, Jill, or John:

    1 assignee not in (Jack,Jill,John)
  • Find all issues where the Assignee is someone other than Jack, Jill, or John whose Atlassian account IDs are abcde-12345-fedcba or fedcb-12345-edcba or cdefb-67895-cbaed, respectively:

    1 assignee not in (abcde-12345-fedcba,fedcb-12345-edcba,cdefb-67895-cbaed)
  • Find all issues where the Assignee is not Jack, Jill, or John:

    1 assignee not in (Jack,Jill,John) or assignee is empty
  • Find all issues where the Assignee is not Jack, Jill, or John whose Atlassian account IDs are abcde-12345-fedcba or fedcb-12345-edcba or cdefb-67895-cbaed, respectively:

    1 assignee not in (abcde-12345-fedcba,fedcb-12345-edcba,cdefb-67895-cbaed) or assignee is empty
  • Find all issues where the FixVersion is not 'A', 'B', 'C', or 'D':

    1 FixVersion not in (A, B, C, D)
  • Find all issues where the FixVersion is not 'A', 'B', 'C', or 'D', or has not been specified:

    1 FixVersion not in (A, B, C, D) or FixVersion is empty

CONTAINS (~)

The "~" operator is used to search for issues where the value of the specified field matches the specified value (either an exact match or a "fuzzy" match — see examples below). For use with text fields only, i.e.:

  • Summary

  • Description

  • Environment

  • Comments

  • custom fields that use the "Free Text Searcher"; this includes custom fields of the following built-in C