Contains operator does not show proper results in JQL filter

Georgi Arnauchkov October 23, 2024

Hi,

I am unable to make the contain "~" show proper results.
I use it to search for the domain of an email in the description field.

 

description ~ "domain.com"

 

text in the description field is seen as:

text text text 'email@domain.com' text text text

 

No results of the above search query are shown.
However, if you use the exact email address is used in the search it shows proper results

e.g.

description ~ "email@domain.com"

 

Is there a way to find all tickets with emails from this specific domain?

3 answers

1 accepted

4 votes
Answer accepted
Lisa Forstberg
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 23, 2024

Hi @Georgi Arnauchkov ,

Welcome to the community!

With JQL you have these options:

description ~ "email@domain.com" => match as it is exact

description ~ "email@*" => will match as a wildcard * works at the end only

description ~ "*domain.com" ==> will not match I am afraid :(

 

I think you have run into this feature request https://jira.atlassian.com/browse/JRACLOUD-27687

 

More information on options here:  https://support.atlassian.com/jira-software-cloud/docs/jql-fields/

 

all the best

/ Lisa

Georgi Arnauchkov October 23, 2024

thank you for your information.
it is sad that this feature request has not been resolved for the past 10 years ....

Like Lisa Forstberg likes this
Lisa Forstberg
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 23, 2024

Agree. 

1 vote
Sravan Indukur
Contributor
October 23, 2024

Hi @Georgi Arnauchkov ,

Rather than using JQL search, switch to Basic, and add the desired custom field. In your case add description. As the field is text, a text box will come there and add the required text for search in that and click on "Update" Button.

This is solves your problem.

Georgi Arnauchkov October 23, 2024

still not showing using the basic option

0 votes
Salih Tuç
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 23, 2024

Luckily, the CONTAINS operator is coming with bunch of pretty features like wildcard (*) or exact word (with the encoded quotes) that you can see here.

 

You can try something like:

description ~ "*@domain.com"
Georgi Arnauchkov October 23, 2024

this gives an error as * or ?  is not accepted at the beginning of the string

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events