QMetry JQL Functions
Introduction
Users can construct Advanced JQL filters using QMetry JQL functions and use the functions wherever JQLs are supported in Jira. These functions will return Jira Stories or Bugs based on the specified arguments related to QMetry test assets within the Advanced JQL Search.
Jira stories refer to Issue Types set as “Story” and Jira bugs refer to Issue Types set as “Bug” under Project Settings > QTM4J Settings > Common Settings > Issue Type.
QMetry JQL functions can be saved, shared, exported, and used in a dashboard, Confluence, and QMetry Reports where Defect and Requirement Filters are provided to generate the reports.
→ Required Permission: Users should have the Execute QMetry JQL Functions permission under Project Settings > QTM4J Settings.
QMetry JQL functions and their usage
The section explains where you can access the feature in QTM4J and how to make further use of it in Jira.
From where to access the JQL Functions?
Go to QMetry > JQL Functions.
The QMetry JQL Functions are displayed on the screen. JQL functions offer enhanced flexibility and power for querying Jira stories and bugs linked to test cases, test cycles, and test executions.
To view the details of the JQL function, click the JQL function in the navigation bar at the left. The details of the function are displayed on the screen at the right.
How to use QMetry JQL Functions?
First, validate the JQL function in the QTM4J application and then use the validated JQL functions in the Jira search.
Step 1. Validate QMetry JQL Functions
Click the QMetry JQL Function Validator button.
The Validator opens with the written query within it.
You can refer to the details provided for the JQL on the screen and modify the query to retrieve the desired records.
The validator shows the check mark if the query is proper and ready to use in Jira.
The validator shows the cross mark if the query contains invalid arguments or values.
Hover over the cross mark to know the error in the query, and correct the JQL query accordingly.
Step 2. Use QMetry JQL Function in Jira
If the JQL is validated successfully in the validator described above, you can use it further in Jira.
1. Copy the validated JQL function by clicking on the Copy icon.
2. Open the Issues page in Jira and switch to the Advanced search to use the JQL.
3. Paste the copied JQL function into the Search box and click Search.
The JQL search retrieves records matching the search criteria defined in the function.
QMetry JQL Functions
The table below displays a categorized list of queries, along with reference links for further details.
Function Name | Description | Reference Link |
---|---|---|
Get a List of Stories based on Test Cases, Test Cycles, or Bugs | ||
qtmj_getStoryLinkedWithTCLike | This function returns a list of stories linked to test cases based on the specified test case filter criteria. | |
qtmj_getStoryLinkedDirectlyWithTRLike | This function returns a list of stories linked directly to the test cycles based on the specified test cycle filter criteria. | |
qtmj_getStoryHavingBugLike | This function returns a list of stories in the project associated with bugs discovered during the executions of test cases or test steps linked to those stories. | |
Get a List of Bugs | ||
qtmj_getBugLinkedWithTCLike | This function returns a list of bugs discovered during all the executions of test cases or test steps based on the specified test case filter criteria. | |
qtmj_getBugLinkedWithTRLike | This function returns a list of bugs discovered during all the executions of test cases or test steps based on the specified test cycle filter criteria. | |
Get a List of Stories based on Test Executions | ||
qtmj_getStoryHavingTCExeLike | This function returns a list of stories where any of their test case executions match the specified execution filter criteria. | |
qtmj_getStoryHavingAllTCLatestExeLike | This function returns a list of stories where every latest execution of their linked test cases matches the specified execution filter criteria. | |
qtmj_getStoryHavingAnyTCLatestExeLike | This function returns a list of stories where any of their latest test case executions match the specified execution filter criteria. | |
qtmj_getStoryLinkedDirectlyWithTRHavingAllTCLatestExeLike | This function returns a list of stories directly associated with test cycles, where every latest execution of their linked test cases in any test cycle matches the specified execution filter criteria. | |
qtmj_getStoryLinkedDirectlyWithTRHavingAnyTCLatestExeLike | This function returns a list of stories directly associated with test cycles, and any of their latest test case executions in any test cycle match the specified execution filter criteria. |