It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

How can I search for more than one word using the "contains" operator?

Hello !

Assuming I need to search a list of different words without having to repeat the query as in the example below:

 

project in (URA) and createddate> = startOfMonth () and status not in (closed, resolved, canceled) and issuetype in (incident, Request) and "Customer Request Type" is not EMPTY and summary ~ "sounds" or project in ( IVR) and createddate> = startOfMonth () and status not in (closed, resolved, canceled) and issuetype in (incident, Request) and "Customer Request Type" is not EMPTY and summary ~ "test"

 

I have to bring an extensive list of results, but I am already exceeding the amount of characters.

 

What can I do?

2 answers

1 accepted

0 votes
Answer accepted

Hi @Bruno Borges

Looking at your query, it looks like the common parameters are:

project in (URA) and createddate> = startOfMonth () and status not in (closed, resolved, canceled) and issuetype in (incident, Request) and "Customer Request Type" is not EMPTY

A few pro-tips on this first:

  • You can group the projects - for example "project in (URA, IVR)"
  • If all the statuses are your "Done" statuses - you could replace the "status not in" part with either "statusCategory != Done" or "resolution is empty" to see open issues. Future proofs you in case more Done statuses are added.

I can think of two methods to make a search for a number of keywords as part of this. The first is to use the OR statement for the keywords. You can surround the keyword queries in brackets to show each word searched for should be considered against the rest of the common parameters - for example:

project in (URA) and createddate> = startOfMonth() and status not in (closed, resolved, canceled) and issuetype in (incident, Request) and "Customer Request Type" is not EMPTY and (summary ~ "sounds" OR summary ~ "test" OR summary ~ "design")

^ This should give you what you need. An alternative - which is useful if you have a large number of keywords or a list which regularly changes - is to save it as a separate filter and search for issues which match it. This stops the query becoming too long due to one parameter - for example, create a filter like this:

summary ~ "sounds" or summary ~ "test" or summary ~ "design" or summary ~ "front-end" or summary ~ "back-end" or summary ~ "QA" or summary ~ "website

Save this filter and in the URL bar it will be given an ID - usually this is a few numbers at the end of the equals sign. You can then build a query like this:

project in (URA) and createddate> = startOfMonth() and status not in (closed, resolved, canceled) and issuetype in (incident, Request) and "Customer Request Type" is not EMPTY and filter = XXXXX

^ This decouples the larger parameter and means you can add or remove words from its filter, and it'll change your main results set to suit.

Ste

Hello @Ste 

 

It worked, thanks for the help.

 

Best regards.

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted in Jira

Demo Den Ep. 7: New Jira Cloud Reports

Learn how to use two new reports for next-gen projects in Jira Cloud:  Cumulative flow diagram and Sprint burndown chart. Ivan Teong, Product Manager, Jira Software, demos the Cumulative ...

245 views 1 2
Join discussion

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you