Availability
- This routine is available starting with katl-commons 1.0.
- This routine is available for Jira server and cloud deployment options.
- Starting with version 4.8.0.10 of Power Scripts an optional param (overrideScurity) will be available and will give the possibility to bypass any issue security set for the current project.
Syntax
selectIssues(jql [, overrideSecurity])
Description
Returns an array with the keys of the issues that matched the search query.Parameters
Parameter name | Type | Required | Description |
---|---|---|---|
search query | string | Yes | Search query containing the details of the returned issues. |
overrideSecurity | boolean | No | Set to true to bypass any issue security. |
Return type
string []
Returns a list of issue keys that match the specified jql.
Example
string jql; jql = "project = PRJ AND reporter in membersOf('Employees') AND status in (Open, 'In Progress', Reopened, Resolved, 'On hold', Assigned, 'Internal QA', 'Results rejected', 'Tested and not delivered', 'Tested and delivred')"; selectIssues(jql);
Result: An array of strings containing the keys of all the issues that are in the project PRJ, with the reporter included in Employees group and the status being one of the above.
Notes
For the search query, please use apostrophe(') instead of quotes(") and double backslashes(\ \ )for escaping characters instead of a single backslash.
See also