Find metric of word frequency in description

Bud Herz January 11, 2022

Background
There are times when we have a collection of bugs in one bug ticket to expedite the dev team fixing everything related to one area.

 

Challenge
Pull metrics that report those bugs within a single ticket so our numbers might show 30 bugs vs 5 Bug tickets. 

 

EXAMPLE DESCRIPTION - 

This bug should have some varied ways to identify multiple bugs in a single ‘parent’ bug.

Bug 1 -

Bug 2

Bug three:

This sentence uses the word bug to confirm it’s excluded from the search.

 

EXAMPLE QUERY (not working) - 

project = BSP AND issuetype = Bug AND description ~ "Bug 1" AND NOT description ~ "bug" ORDER BY Key ASC

 

 

2 answers

1 accepted

0 votes
Answer accepted
Bill Sheboy
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.
January 11, 2022

Hi @Bud Herz 

I am a bit unclear what you are expecting the results of that search to be: nothing or something.  Would you please clarify?

Regarding the query you provided, the contains operator ~ can do an exact match if you escape the search in quotes, like this:

project = BSP AND issuetype = Bug AND description ~ "\"Bug 1\""

But, you are also trying apparently to exclude things which contain "bug", perhaps with !~ and so that may not work as you expect: one search string is a subset of the other due to the "fuzzy" searching for contains.

Kind regards,
Bill

Bud Herz January 12, 2022

Hey @Bill Sheboy 
We have plenty of bugs that may casually mention other bugs in their descriptions. Things like "...fix may still be blocked by bug BSP-2345". 

I am hoping to find results specific to the format we use when we list multiple issues in a single bug. Most often the method would be like "Bug 1" 

Now using what I thought was a specific search for "Bug 1" instead returns everything with "Bug" anywhere in the description. So what I started with was - 

project = BSP AND issuetype = Bug AND description ~ "Bug 1" ORDER BY Key ASC

For me, that does not return only "Bug 1" results. I have studied the syntax help page and swear I am doing it how it should be used, but obviously I'm missing something simple.

Bill Sheboy
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.
January 12, 2022

Thanks, Bud.  To exactly search for "Bug 1" you will need to escape the quotes like this:

project = BSP
AND issuetype = Bug
AND description ~ "\"Bug 1\""
ORDER BY Key ASC
Bud Herz January 13, 2022

Thanks @Bill Sheboy , but unfortunately that still returns everything where the word bug shows in a description. I've tried to play with that to figure out if you had a typo, but I haven't had any luck yet. 

Bill Sheboy
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.
January 13, 2022

I just re-tried it and it worked for me.  Perhaps try checking your field setup to see if the type / editor has been changed, as that might impact the contains operator.  Otherwise I'd check with support as that should work for Jira Cloud.

Like Bud Herz likes this
0 votes
Bud Herz January 13, 2022

Bill seems to have the correct answer, but it looks like a setup problem in my Jira needs investigating. 

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
TAGS
AUG Leaders

Atlassian Community Events