In this video, you will learn the different features in Jira that help you write JQL queries.
These include the autocomplete feature, the Spacebar feature, and finally, the Syntax
Help feature.
JQL syntax may seem complicated, and you might feel like you have to remember all the syntax
to use it.
You don’t!
Jira comes with these three helpful features for writing syntax.
First is the autocomplete feature.
Let's take a look.
As you type a query in JQL, Jira will provide a list of values to select.
If you typed ‘s' and 't', Jira would show the fields that start with 'st', like 'start
date', 'status', 'statusCategory', and so on.
You can then select the text you want to use.
Notice that Jira will also tell you if a query is valid by displaying a green tick.
If it is invalid, Jira displays a red 'x' instead.
Next is the spacebar feature.
If you enter an element in JQL and hit your spacebar, Jira will automatically tell you
what options are available based on what you have already entered.
This feature helps eliminate the need to memorize fields, values, operators, keywords, and functions.
It also helps to keep your queries valid!
Let’s try it out.
Start a JQL query with the 'duedate' field and hit the spacebar.
Jira shows us the operators available for the 'duedate' field.
Let’s select the 'greater than' operator and hit the spacebar again.
Now, Jira will show us the functions that are available to be used with the 'greater
than' operator.
Let’s look at another example.
Start a JQL query with the 'project' field and hit the spacebar.
Jira will show a list of operators for the project field.
These are different than what we saw for the 'duedate' field.
This is because operators are based on the field type.
Select the 'equals' sign operator.
When you hit the spacebar, Jira will show a list of the projects.
After we select a project, Jira then shows us a list of keywords allowing us to expand
our search criteria.
The final help feature we’ll cover is Syntax Help, which opens the Atlassian Support page
for Advanced search.
Navigate to it by selecting the 'question' symbol in the JQL text entry field or the
Syntax Help line from the JQL menu.
Once it opens, you'll be able to see that there are separate pages for fields, functions,
operators, and keywords that include explanations and examples for each element.
You don’t need to have all JQL syntax elements memorized to use JQL.
Jira is set up to help you automate writing JQL as you go.