BA Prince the B.A. Subscribe

Home / Jira & Confluence for BAs

JQL Basics: Search Jira Like a Pro (and Save a Filter)

JQL Basics: Search Jira Like a Pro (and Save a Filter)

Watch on YouTube Subscribe

Learn JQL, the Jira query language, with one real example: every open bug in a project, newest first. Field, operator, value, AND, ORDER BY, then save it as a filter you can reuse.

Step by step

What is JQL

  1. JQL basics. JQL lets you ask Jira a precise question, such as which bugs are still open or what the team finished this week. Here it is built up with one real example: every open bug in a project, newest first.
  2. Switch to JQL. On the search page, switch from basic search to JQL. You now get a text box where you type the query yourself.
  3. Field, operator, value. Every JQL condition reads like a short sentence: a field, an operator and a value. In project = SCRUM, project is the field, = is the operator and SCRUM is the value.

Build a query

  1. Only bugs. To find the bugs, click in the JQL box, press Ctrl+A to select the text that is already there, and type project = SCRUM AND type = Bug. AND joins 2 conditions, and both must be true for an issue to show.
    project = SCRUM AND type = Bug
  2. Search. Click Search. Jira lists 3 bugs in the SCRUM project.
  3. Not done. To keep only the unfinished ones, add AND statusCategory != Done to the end of the query. != means "not equal to", so finished bugs drop out.
    AND statusCategory != Done
  4. Newest first. Then add ORDER BY created DESC. This sorts the results by the date each bug was created, newest at the top.
    ORDER BY created DESC
  5. Search. Click Search again. Now 2 open bugs show, newest first.

Save it

  1. Save filter. You will run this query often, so save it as a filter. Give it a name that says what it shows, here Open bugs - Online Shop. Click Save.
  2. Your filter. The filter Open bugs - Online Shop now has its own page. Open it any time to rerun the query, or share it with your team.

Recap

  1. Field, operator, value. In short: each condition is field, operator, value. AND joins conditions, ORDER BY sorts, and saving the query as a filter lets you reuse it.

Common mistakes

  • Using status != Done instead of statusCategory. Many workflows finish issues with statuses like Closed or Resolved, so status != Done still shows them. statusCategory != Done covers every finished status at once.
  • Values with spaces and no quotes. A value like In Progress breaks the query when typed bare. Put it in double quotes, for example status = "In Progress".
  • Putting ORDER BY in the middle. ORDER BY only sorts and must come last. Add every AND condition first, then end with ORDER BY created DESC.
  • Mixing AND and OR without brackets. A query like type = Bug OR type = Story AND statusCategory != Done does not group the way most people expect. Use brackets: (type = Bug OR type = Story) AND statusCategory != Done.

When a business analyst uses this

Before a release sign-off, a business analyst saves project = SCRUM AND type = Bug AND statusCategory != Done ORDER BY created DESC as a filter and shares it with the product owner. Everyone then reviews the same live list of open bugs, instead of a spreadsheet someone copied by hand.

Questions people ask

What are the basics of JQL?

Each condition is a field, an operator and a value, like project = SCRUM or type = Bug. AND joins conditions so all of them must be true, and ORDER BY at the end sorts the results.

What is a good JQL example to start with?

project = SCRUM AND type = Bug AND statusCategory != Done ORDER BY created DESC lists every unfinished bug in the SCRUM project, newest first. Change the project key to use it on your own project.

How do I reuse a JQL query in Jira?

Save it as a filter and give it a clear name. The filter gets its own page, so you can open it any time or share it with your team.

More in Jira & Confluence for BAs