Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Can you use JQL on a User Picker (multiple users) custom field to query by number?

I have a custom field in JIRA of type "User Picker (multiple users)". Let's call it Approvers. 

I'd like to write some JQL like "Approvers" > 3, but JIRA is unhappy about that saying "The operator '>' is not supported by the 'Approvers' field.".

Is this even possible?

Thanks!

2 answers

In case others run into the same problem, I wound up using automation to solve my problem.

Specifically, I wound up creating a hidden number field, that when the "User Picker (multiple users)" field was updated, it would use issue.field.customfield_1234.size to update the count of the hidden number field.

Is this only available on cloud?

I tried this on server version - use {{issue.customfield_1234.size}} - updates the number field.

Tested with {{issue.field.customfield_1234.size}} no update to number field

Tested with {{issue.customfield_1234.size[0]}} no update to number field

This is for the number of people inside of a multi people picker field.

1 vote
Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
Oct 31, 2017

That's because "approvers" is a list of users.  The question you're asking if translated into plain English is "Are Dave, Alice and Bob greater than three?".  Which is not a valid question.

You will need to set up a sensible question - either create a JQL function that will count up the number when given a field name, or a custom scripted field that can add it up.  Either way, you'll need an add-on of some sort to provide the code to do this.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events