10 2. JPQL Language Reference

For example, suppose one issue contains the text phrase “VSX will crash” and another issue contains the phrase “VSX will not crash”. A text search for “VSX will crash” will return both of these issues. This is because the words will and not are part of the reserved words list. This page provides information on the syntax for searching text fields, which can be done in the quick search, basic search, and advanced search.

jql documentation

Furthermore, JPQL queries can be declared statically in

metadata, or can be dynamically built in code. This chapter provides the full

definition of the language. The response consists of an array of projects and each project contains an array of issue types that apply
to that project. The response consists of an array of projects and each project contains an array of issue types that
apply to that project.

Find methods

Valid values include
“favourite” for returning only favourite dashboards, and “my” for returning
dashboards that are owned by the calling user. In order to minimise network traffic and server CPU usage, the JIRA REST API sometimes uses a technique called
expansion. When a REST resource uses expansion then parts of that resource will not be included in the JSON response
unless explicitly requested. The way to request those fragments to be included is by using the expand
query parameter. It’s helpful to use the “project” keyword as a filter so that I don’t get confused about which tickets I’m looking at. You can search by issue type name or issue type ID (i.e. the number that Jira automatically allocates to an issue type).

jql documentation

It is even valid for a scalar function (that is,
a function whose JqlFunction.isList method returns false) to return multiple QueryLiteral objects. In such a situation it is the JQL what are JQL queries and how to use them clause the function is being used with that decides what this means. All of the
core Jira JQL clauses simply treat such a situation as an OR between each of the returned values.

About Atlassian

You can use this resource to assign issues when the user submitting the request has the assign permission but not the
edit issue permission. The maximum number of users to return (defaults to 50). If
you specify a value that is higher than this number, your search results will be truncated. An optional filter that is applied to the list of dashboards.

jql documentation

Note, it is safer to search by resolution ID than by resolution name. It is possible for your Jira administrator to change the name of a resolution, which could break any saved filter that rely on that name. Resolution IDs, however, are unique and cannot be changed. Search for requests by the channel that they were created by. For example, you could search for all requests that were emailed to the service project, or all requests that were sent from a customer portal.

Perform searches based on the start of the current month. See also startOfDay, startOfWeek, and startOfYear; and endOfDay, endOfWeek, endOfMonth, and  endOfYear. Perform searches based on the start of the current day. See also startOfWeek, startOfMonth, and startOfYear; and endOfDay, endOfWeek, endOfMonth, and endOfYear. To find issues that are running based on calendar hours, use withincalendarhours().

jql documentation

You can filter on user attributes connected to current reporter in custom fields by invoking this function in your AQL query. Note that the attribute used in the query for filtering needs to be of type User. The table below describes the keywords supported along with their respective examples. This query will return all issues with the fix version 7.8.0 and open pull requests linked to them. The “IN” operator is used to search for issues where the value of the specified field is one of multiple specified values.

  • Values not passed are assumed to indicate
    no change for that field.
  • Instead of the objectId, you can always use the Key attribute on any object type to search for a particular object.
  • Perform searches based on the latest released version (i.e. the most recent version that has been released) of a specified project.
  • So in this case, the property name serves as a sort of path.
  • A JQL query can easily find the issues that aren’t meeting the SLA.

While this functionality is very useful, it also allows information to be leaked. For example, let’s say you have a filter that contains assignee in exampleFunc(Administrators, Proj) and you
share the filter with Janice who cannot see Proj. The search will not return any results, however, Janice will
know that a project called Proj exists even though she does not have permission to see it. The JqlFunction.getDataType method is called to determine the type of data the function returns.

Note that the createmeta resource has been reported to cause issues especially on larger instances. These issues have involved the size of the response or Jira running out of memory. That is why we decided to remove this endpoint in Jira 9.0. If you run Jira 8.4 or later, disable the endpoint and replace it with the other calls we’ve created to remedy the issue.

Advertisement

No comments.

Leave a Reply