
Jira Cloud: Easy Ticket Filtering Using JQL Query
Jira Query Language (JQL) is your secret weapon for mastering Jira. This potent tool lets you effortlessly filter, sort, and manipulate data within your Jira instance, whether you’re juggling projects, tracking support tickets, or analyzing complex workflows.
By learning JQL, you’ll streamline your workflow and gain valuable insights into your data. This guide will introduce you to the fundamentals of JQL and provide practical examples to help you filter tickets with precision. Let’s dive in!
What is JQL?
Jira Query Language (JQL) is more than just a search tool; it’s a powerful way to precisely pinpoint and organize issues within Jira. By crafting custom queries, you can:
- Target Specific Issues: Filter issues based on criteria like status, assignee, priority, and more.
- Build Complex Searches: Combine conditions using AND, OR, and NOT operators to create intricate filters.
- Customize Your View: Sort and order results to prioritize or categorize your work efficiently.
Even if you’re not a coding expert, JQL’s simplicity and Jira-specific nature make it easy to learn and use.
Let’s Get Started!
To begin our JQL journey, click your mouse within the Search bar and navigate to the bottom to select View All Issues. To the left of the search area, click on JQL this will switch the search bar to the JQL format. This is where the magic happens! You can now enter JQL queries to refine your search results.
Basic JQL Queries
Let’s explore some fundamental JQL queries to grasp the basics:
- Find Issues by Status
status = "In Progress"
- This query will return all issues with the status “In Progress.”
- Find Issues Assigned to You
assignee = currentUser()
- This query will show all issues assigned to the currently logged-in user. It’s great for creating personal dashboards!
- Filter by Project
project = "IT Support"
- This query will return all issues in the “IT Support” project.
- Combine Conditions with AND
project = "IT Support" AND status = "Open" AND priority = "High"
- Here, you’re filtering issues that are in the “IT Support” project, have a status of “Open,” and a high priority.
- Find Issues by Date Range
created >= startOfMonth() AND created <= endOfMonth()
- This query finds all issues created in the current month. JQL offers a range of date functions, like
startOfWeek()
,endOfDay()
,-1w
, and more, so you can filter by dynamic time ranges.
- This query finds all issues created in the current month. JQL offers a range of date functions, like
- Using Wildcards in Text Searches
summary ~ "login*"
- The
~
operator performs a “contains” search, useful for finding tickets with keywords. In this case, it will find issues with summaries that contain “login.”
- The
- Order By for Sorting
project = "IT Support" AND status = "Open" ORDER BY priority DESC, created ASC
- This query finds all open issues in the “IT Support” project, orders them by priority (highest to lowest), and then by creation date (oldest first). Use sorting to help prioritize the work you see.
- Group Issues Using Labels
labels in ("urgent", "client")
- If you’re using labels like “urgent” or “client” to mark important issues, this query will return all issues tagged with those labels.
- Filter by Custom Fields
"Customer Type" = "VIP"
- Custom fields can be referenced in JQL if you’ve set them up. In this case, a custom field called “Customer Type” with the value “VIP” is used to filter out specific client issues.
Ok, so there are some basic JQL queries to get you started. Let’s dive into some practical JQL query examples to see how you can leverage this powerful tool in your daily work.
Practical Use Cases
- Daily Stand-Up Filter
assignee = currentUser() AND (status = "In Progress" OR status = "To Do")
- This filter shows you all tasks assigned to you that are either in progress or in the to-do list – perfect for a quick stand-up check.
- Find Overdue Tickets
due < now() AND resolution = Unresolved
- This query helps you find overdue tickets by identifying any unresolved issues with a due date in the past.
- Monitor SLA Compliance (Jira Service Management)
"Time to resolution" < remaining() AND resolution = Unresolved
- Use this query to monitor SLA compliance by showing unresolved tickets with remaining SLA time below the threshold.
Tips for Using JQL Efficiently
If you frequently use certain queries, save them as filters. You can then use them on dashboards, in reports, or even share them with your team.
Integrate JQL-based filters into Jira dashboards to visualize your data. This can be especially helpful for tracking project progress, ticket volume, and priority distribution.
Jira’s search bar has auto-complete, which helps you build queries faster by suggesting field names and operators.
JQL is flexible, so don’t be afraid to experiment! Test out different conditions and operators to get a feel for what’s possible.
Mastering JQL can revolutionize your Jira workflow, saving you valuable time and effort. By crafting precise JQL queries, you can effortlessly filter tickets, prioritize tasks, and ensure nothing slips through the cracks. Whether you’re hunting for specific tickets or analyzing broader trends, JQL makes it easy to navigate your Jira data and find exactly what you need.
I have create a separate page with an ongoing list of JQL queries you may find useful. Check it out!
I hope you found it helpful!
Categories
Recent Posts
- PowerShell: How to Add an Alias to Every Users Mailbox and Groups in Microsoft 365
- Slack: Disable Entra ID User using a slash command.
- Slack: Retrieve Entra ID (MS365) User Information with a slash command.
- Jira Cloud: Disabling Entra ID User Accounts via Automation and Microsoft Runbook
- Jira Cloud: Restart an Azure VM using JSM Assets and Automation