Scriptrunner versionMatch function with regular expression for multiple matches

I am trying to query all issues that are contained in all 5er and 6er versions of our product by using the versionMatch function supplied by Scriptrunner.

However the following regular expression does not work.

affectedVersion in versionMatch("(^6.*)|(^5.*)")

It returns more versions than just the two provided versions.

1 answer

This widget could not be displayed.
Thomas Schlegel Community Champion Apr 19, 2017

Hi Christian,

your JQL works fine in my Jira. Could you please give us an example of the false version name? 

my mistake, i forgot to escape the dots. Thanks, anyway!

Thomas Schlegel Community Champion Apr 20, 2017

you're welcome :-)

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted yesterday in Jira

Atlassian Research Workshop opportunity on Sep. 28th in Austin, TX

We're looking for participants for a workshop at Atlassian! We need Jira admins who have interesting custom workflows, issue views, or boards. Think you have a story to sha...

54 views 2 2
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you