This JQL function returns users with a certain role in a certain project.
Syntax
usersWithRoleInProject(role, projectKey) #Output: Text list
Examples
|
Parser expression |
Description |
|---|---|
|
Bash
|
This example returns all issues where the current assignee belongs to the Developers role in the CRM project. |
|
Bash
|
This example returns all issues where the current reporter belongs to the Administrators role in the HR project. This function returns users that belongs to the Administrators role in the PR project, but the whole JQL will return every issue whose reporter is in the returned list, even if it returns an issue from a different project. |
Additional information
Parameters used in this function
|
Parameter |
Input (data type) |
Description |
|---|---|---|
|
|
text |
Text containing a valid project role name. |
|
|
text |
Text containing a valid project key. |
Output
This function returns a Text list
The result is not what you expected? The number of returned issues feels too low?
By default, the maximum number of issues that will be returned by the JQL subquery, and thus can be processed by the logical expression is 1000.
To ensure the performance of your entire Jira instance, we limit the execution of the JQL function in terms of issue count and execution time. Please refer to your admin if you need to change the Performance settings .
📚 Use cases and examples
| Use case | JQL function |
|---|---|
| Retrieve all tickets assigned to a developer |