Custom Functions for JQL

Manoj Joshi May 16, 2023

How to write custom jira functions to use in JQL. For ex: i want to find all the jiras that are updated by any of {user1, user2, .. user10} in the last 1week."

1 answer

1 vote
Ash Yadav - VMotion IT Solutions
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 16, 2023

Hi @Manoj Joshi 

 

Maybe something like this should help? 

updated >= -1w AND assignee in (USER_GOES_HERE) order by created DESC

 

If you're looking to check a range of users, it might be more effective to add those users to a group and check if either one is an assignee of said group? 

Here's an example: 

updated >= -1w AND assignee in (membersOf(site-admins)) order by created DESC

 

KR, 

Ash 

Manoj Joshi May 16, 2023

Thanks Ash for the quick response. I was also thinking about the user groups. However, my manager wants me to write custom functions to use in JQL to address dynamic user lists rather than predefined user groups. Can you please point me to some resources on how to write custom functions. One i researched so fat talks about installing Script Runner, Script Fragments and use Java code to make custom functions..

Ash Yadav - VMotion IT Solutions
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 17, 2023

ScriptRunner is quite powerful and if you're not familiar with it, it can take a while to get it to do what you want. 

 

Can you elaborate on what the requirement is a bit more? Maybe there is a better way to do this but I'll need to know the idea behind it. 

 

KR, 
Ash 

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
PERMISSIONS LEVEL
Site Admin
TAGS
AUG Leaders

Atlassian Community Events