Hi,
I am trying to use the lookup work items component in Jira Automation to iterate on a result but I can't return the set of results that I am expecting.
My rules are as follows:
Create variable:
-Name: updatedmetrics
-smart value: {{issue.customfield_15855}}
lookup work items:
type IN ("New Metric Task") AND "associated cc tickets[short text]" ~ "{{updatedmetrics}}"I am also putting this into the log.
This smart value is a comma delimited list (say 123,124,125,126). I have 4 separate tickets where the field 'associated cc tickets' contains either 123, 124,125, or 126.
In the log, it shows that the above jql resolves to the following:
type IN ("New Metric Task") AND "associated cc tickets[short text]" ~ "123,124,125,126"When I search for this within Jira, the 4 issues show up as expected:

However the result of the lookup in the automation shows "A search during custom value definition found no work items."
If I update one of these fields to be explicitly `123,124,125,126` (instead of one element individually) then the automation rule runs and returns the appropriate ticket. Therefore it seems to me that there's something specific about the contains operator that works in normal Jira search but not in automation. I tried to move this rule logic to be within a for each branch but the result is the same.
The `IN` operator errors here (maybe not useable for custom fields?) so I'm not sure what else to try. Thanks in advance!