Hello.
We recently started to use Insight in our Jira Software. We have created the object schema. Inside this scheme we have objects with 2 insight custom field with multiple selection: 'Country' and 'Month'.
Goal: on the creation of an issue, filter the objects depending the 'Country' and the 'Month' and set all the objects in a new insight custom field 'Camp'. It would be similar to the IQL: Country in ({values of the custom field 'Country'}) AND Month in ({values of the custom field 'Month'})
Problem: in a first instance, when you set the IQL filter to this new insight custom field, due to the multiple selection, when you select more than 1 value it change the option 'IN' to 'AND'. If for example you select 2 countries and 1 month it make the following: Country in (value1) AND Country in (value2) AND Month in (value1) instead of Country in (value1, value2) and Month in (value1).
Solution: as solution I created a behaviour with the add-on "ScriptRunner" to parse the value of the custom fields, make the IQL search correctly and set the obtained values to the custom field 'Camp'.
Problem of the solution: after search and obtain the correct objects from insight, I can't find the way to set the obtained objects in the new custom field 'Camp' from this behaviour on ScriptRunner. I have the id of the objects.
In summary, in my script I can't set the objects on a insight custom field once I have find this objects. Please, help me to find the solution. Thanks in advance.