Searching for $ symbol doesn't work in JIRA

Erica Larson February 13, 2018

I have made multiple different attempts to search for $ in any text field and I can't get any of them to work.  I want to find the symbol in the summary or a custom text field.  I don't receive an error message but no results populate.

  • summary ~ '$'
  • summary ~ "$"
  • summary ~ "\"$\""
  • summary ~ '\\$'
  • summary ~ '\\$\\'
  • summary ~ "\\[$\\]"
  • summary ~ "0$0"
  • summary ~ \u0024
  • summary ~ "\u0024"

Pages I found with recommendations but none of them work for $ symbol that I have tried.

https://confluence.atlassian.com/jiracoreserver073/advanced-searching-861257209.html#Advancedsearching-restrictionsRestrictedwordsandcharacters 

https://confluence.atlassian.com/jiracoreserver073/search-syntax-for-text-fields-861257223.html#Searchsyntaxfortextfields-escapingEscapingspecialcharacters:\or\\

I also tired searching $ on Confluence and I couldn't populate any results.

1 answer

1 accepted

2 votes
Answer accepted
Andy Heinzer
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
February 21, 2018

Hi Erica,

Jira's JQL can't perform searches for just a single character, or for fragments of words.  Instead Jira has to search for whole words.  This is a known limitation explained in https://confluence.atlassian.com/jiracoreserver073/search-syntax-for-text-fields-861257223.html#Searchsyntaxfortextfields-Wholewordsonly

However I think there might be a way to get around this with the use of a plugin for Jira.  For example, I believe that the Scriptrunner plugin will allow you to use regex searches of specific issue fields in Jira per https://scriptrunner.adaptavist.com/latest/jira/jql-functions.html#_regular_expressions

If you had this plugin with Jira, I believe you could then do a search such as

issueFunction in issueFieldMatch("", "summary", "\$")

which I believe will then be able to help find issues that contain that specific character in their summary field.

Of course there might exist other plugins in Marketplace that could help here as well.

Erica Larson February 28, 2018

Thank you for your reply Andrew.  We don't have Scriptrunner at this time but we are looking into purchasing it.  I will have to give that a try when we install it.

Erica Larson April 10, 2018

Tested the suggested JQL above using Scriptrunner. I was able to get it to work using the following:

issueFunction in issueFieldMatch("", summary, \\u0024)

 Used "\$" still threw an error.  

Andy Heinzer
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
April 12, 2018

Ah, right that is a reserved JQL term too.  Sorry about that.  I see you found the \\u0024 method to find that character.  Alternatively, you can also use an additional \ character to escape the other escaping character \

 

In which case you could use something like

issueFunction in issueFieldMatch("", "summary", "\\$")

Thanks for posting back with this detail.

Jordan Janis March 21, 2019

Thanks for this!  Was racking my brain trying to search for equals sign "=". Naturally it took me two hours to come across this post but I'm thankful I did.

One note, as the ScriptRunner documentation states, "Performance will be roughly proportional to the number of issues selected by the subquery, so use the query that selects the smallest set of issues you can, eg just your projects".  The query is slow if not qualified with additional search terms, so be aware.

Suggest an answer

Log in or Sign up to answer