2
votes

I have a custom User Picker (single user) field. This field has a space in the name (e.g. "User Picker"). I cannot remove the space from this name as it is used in searches by many other people.

I want to search for all the issues where the assignee != User Picker. I installed Script Runner and added this in the advanced search:

issuefunction in expression("", "assignee != User Picker")

I got the error:

expecting EOF, found 'Picker' @ line 1, column 25.

I then searched the net and found that I should be able to use a custom field ID. For example, for cf[12345] I should be able to use:

issuefunction in expression("", "assignee != customfield_12345")

This results in the error:

Field customfield_12345 not found or not a Number or Date custom field.

Is there a way of using User Picker custom fields with spaces in expressions?

1

1 Answers

0
votes

The documentation of the expression issueFunction is available here.

It mentions:

What you can compare are the system estimate and date fields, and any numeric, date, or datetime custom field.

You're trying to compare User fields, but expression cannot be used for that.

To get the functionality that you're looking for, you'll have to implement your own custom JQL function.