Some issues not showing up in searches in Jira

Jacob Marner September 30, 2014

For instances if I do a simple search for "dist" I get 2 results. "distr" gives 0 results but "distract" gives 96 issues.

This seems very illogical to me. Is it a bug or am I doing something wrong.

I have tried re-indexing JIRA but it did not do any difference.

3 answers

1 accepted

0 votes
Answer accepted
Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
October 1, 2014

This is down to the "word stemming" in the Lucene search.  I don't know the exact rules, but I suspect

  • dist maybe being seen as a word in it's own right.  Incorrectly of course, it's not a real word, but gets used in "Linux dist".  More likely is that it is seen as an abbreviation for district or distance. Or probably as a fragment that doesn't relate to any particular word.  So your 2 results probably just contain the fragment "dist" on its own, or possibly one of the words it recognises dist as an abbreviation for.
  • distr is definitely just a fragment, the stemming can't relate it to any word at all.  I suspect the 0 result is correct in this case
  • distract is definitely a full word, so it'll be finding them, but the word stemming will also probably pick up distracts, distraction, distracting, and other plurals and variants

You can turn off word stemming at Admin -> General Configuration,

But be warned that if you do, it really will stop stemming, so you won't get any partial words or cross over from American English into English and so on.  For example Americans use "customized colors", and the English phrase is "customised colours", so a search for "customised" and "colors" will find nothing (a stemmed search should find both phrases)

Jacob Marner October 2, 2014

Yes stemming seems to explain it. I read a bit up on Lucene search, and I am just surprised that you can search for any kind of partial word. Is there any way to make JIRA actualy just find the the given substring? When I use the "~" (contains) operator I expect it to find all the places where that substring is found.

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
October 2, 2014

I think ~ needs to be told more, I don't think "contains" is strictly the right way to describe it. It's not quite a "like" either, so I don't want to use that word either. If you use "~ colour", I'd expect to see color, colour, colors and colours pulled out, but not words like colourisation. But if you said "~ "colour*" ", then I would. The difference is that without the wild-card, I think it just looks for the whole word you give it (plus stems), but with the wildcard, it'll behave more like a substring search. So, where " ~ distr " gets you nothing, try " ~ "distr*" " and I think you might have more luck, with it pulling out distribution, district, distress and so-on

0 votes
Jacob Marner September 30, 2014

text ~ "dist"

text ~ "distr"

text ~ "distract"

Jacob Marner October 1, 2014

Bump.

0 votes
Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
September 30, 2014

What searches are you doing exactly?  Could you swap to advanced search on the view and see what JQL you are ending up with on each search?

Suggest an answer

Log in or Sign up to answer