Wildcard searches using phrases syntax does return results.

Still need help?

The Atlassian Community is here for you.

Ask the community

Problem

JIRA's search engine is built using Apache Lucene. When searching in JIRA using phrasing with wildcards the results may not include what you are expecting. This could be caused by the fact that the version of Lucene used by JIRA only supports single and multiple character wildcard searches within single terms (not within phrase queries). As explained hereA phrase is a group of words surrounded by double quotes - for example "You've got JIRA issues".

This was fixed in Lucene as part of LUCENE-1486.  There is an existing request to update the version of Lucene in JIRA:  JRA-43405 - Getting issue details... STATUS

Diagnosis

  • Set the package com.atlassian.jira.issue.search.providers to DEBUG level logging to see how JIRA converts JQL into Lucene queries. See how to Change logging levels in Jira Server
  • Create two issues with summaries:
    • Placer One: MBL-RFT-00063
    • Placer One: MBL-RFTO-000045
  • Search in JIRA's Issue Navigator. See Using the Issue Navigator:
  • summary ~ "\"Placer One: MBL-*\""
    • You'll see the resulting Lucene query in the logs:
    • +pq_support_summary:"Placer One MBL"

As you can see above, JIRA removes the wildcard character when generating the Lucene query.

Workaround

Search on a per-term basis (so wildcards can be used) instead of searching with an entire phrase. So you need to remove the escaped inverted commas. 

Here's some sample JQL that successfully returns the issues:

  • summary ~ "Placer One MBL R*"
  • summary ~ "Placer One MBL RT*"
  • summary ~ "Placer One M* R*"
  • summary ~ "Placer One M* RFT*"
Last modified on Feb 26, 2016

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.