Forums

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

Why would a custom field suddenly be unable to use operators like equals?

NancyB455
Contributor
July 24, 2019

This project has a custom field "Country" which uses a pick list.  Queries like "Country = France" worked fine.  Suddenly today, "Country = France" returns an error message "The operator = is not supported"  The only operators that work are IS and IS NOT empty.  However, using the code (i assume it is some kind of unique field identifier) "cf[14002] = France" does work.

I'll add that a few months ago, we added another custom field "country" (note the lower case") that is a free text field.  But even typing "country" (or 'Country') ~ France" returns the error message.

Any ideas what could have happened?  Or what I check?  (This is JIRA on the server.)

Thanks - Nancy

2 answers

2 votes
Matthias Gaiser _K15t_
Community Champion
July 24, 2019

Hi @NancyB455,

you've analyzed your problem very good yourself. There's not much too add.

JQL does not treat field names case sensitive. This means if you have fields with the same name, Jira does not know to which field you are referring to. Please see also JRASERVER-59476 for a confirmation.

I'd recommend to either:

  • rename one of the fields
  • use the cf[14002] syntax. The number is the internal id of the custom field. This knowledgebase article explains how to get it.

Cheers,
Matthias.

0 votes
NancyB455
Contributor
July 24, 2019

I really appreciate your response, and I intend to talk to an administrator about what problems would be caused by changing the name of the "lower case" country.

 

But...this WAS working!  We added that other "country" at least a month ago.  Any idea why it would work and then not work?

Josh_Kochelek__Modus_Create
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.
July 24, 2019

I'm not 100% clear on the DB structure, etc., but having two different objects with the same name can cause lots of strange issues, depending on the scenario. This is a perfect example of why custom fields should have unique names.

However, to @Matthias Gaiser _K15t_ 's point, as a rule, you should reference custom fields by ID, and not name to avoid issues. 

Like Matthias Gaiser _K15t_ likes this

Suggest an answer

Log in or Sign up to answer