Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

JQL truncation issue when using ~ with customfield

Chuck Turner
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
March 9, 2022
I am trying to create a URL with a JQL search parameter that matches the filename selected by the user to a customfield.

Example:

https://<mysite>/issues/?jql=cf[10213]~Here-is-a-very-long-file-name+ORDER+BY+updated+DESC

The issue is that if the search string contains 6 dashes, it fails to find anything. At first I thought it was a truncation issue, so I started shortening my search string and it did work. But it is not simply truncation at work here.

What is actually happening is that if there is more than one character after the 6th dash, the search will fail with no results returned. If I shorten it to the 6th dash +1 then it returns the expected results.

This-is-a-file-name-with-s|even-dashes  26 chars
This--is-a-short--f|ilename             19 chars
This_is_a_ridiculously_long_filename    no dashes, no problem

Has anyone run into this and found a workaround?

 
 

1 answer

1 vote
Fabio Racobaldo _Catworkx_
Community Champion
March 9, 2022

Hi @Chuck Turner ,

probably error is not related to parameter lenght but to encoding. Please, try to perform request after encoding your jql using https://www.urlencoder.org/

Please, let me know if it works.

Fabio

Chuck Turner
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
March 9, 2022

Hi Fabio. Encoding doesn't change the dashes and the results are the same. 

I get the same behaviour if I type the query into the search filter on the JIRA dashboard.

Suggest an answer

Log in or Sign up to answer