Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Filter Jira Issues (Work Items) by Comment Labels Using the New “CommentWithLabels” JQL Function

Here’s the scenario: You’re knee-deep in support requests, product feedback, and bug reports. Comments are flying in across Jira work items (issues as we all know them before). Internal notes, customer replies, support agents answers, you name it.  

In previous articles, we’ve seen how to properly label comments with Jira Comment Toolkit. But here’s the thing—how do you actually find work items with specific labelled comments? Obviously, scrolling is not the answer. A tailored JQL function is!

A dedicated JQL function to filter Jira work items

You’re a support agent tasked with creating dedicated troubleshooting articles in Confluence. Your starting point is, of course, Jira Service Management. There, you need to find all resolved work items with responses worthy and lengthy enough to be included in Confluence. But you’ve already tagged them with the label “Troubleshooting”. 

Rather than opening each ticket and reading every single comment, now you can just run a simple JQL query, instantly see all relevant work items.

How to Get Started with JQL Filtering for Comment Labels

So here’s how you do it. We've added a brand-new JQL function into the Comment Toolkit: CommentWithLabels

This function lets you filter Jira work items based on which labels were applied to the comments inside. You just pass in the labels you’re interested in—each as a string (inside double quotes " "), separated by commas.

Run that in the JQL search bar, and there you have it—you’ve got a filtered list of work items that include at least one comment with the labels that you’ve specified, in our example “Troubleshooting”. 

You can save your new filter and choose which users can access and edit it. This allows you and your teams to instantly get filtered results without having to run the function over and over again.

But it gets better—you can combine this with other JQL functions to get even more specific. Here are a couple of quick examples:

  • Show all completed work items with labeled comments:

statusCategory = Done AND issue in CommentWithLabels("")

  • Find work items resolved in the last week with relevant comment labels:

resolutiondate >= -1w and issue in CommentWithLabels("") 

  • Filter by a specific project:

project = "DC Apps Support" AND issue in CommentWithLabels("")

  • Narrow results by issue type (e.g., only Bugs):

issuetype in (Bug) AND issue in CommentWithLabels("")

These are just starting points—the possibilities are endless when you combine the CommentWithLabels function with Jira’s existing functions. 

And there you have it! The brand new JQL function is available on Jira Comment Toolkit. If you’d like to learn more and explore more features to better label and manage your Jira comments, make sure to give the app a try. And of course, we really value your feedback. Feel free to leave your questions or suggestions here in the comments below or contact our support team.


0 comments

Comment

Log in or Sign up to comment
TAGS
AUG Leaders

Atlassian Community Events