Hi all,
I'm trying to get a list of several JQL results in one email.
I tried with a lookup issue and a smart variable to capture it, but it only returns the latest lookup issue and not all of them. Is it possible to get it working in one email?
As far as I remember, the Lookup Issues action collects the resulted issues to the {{lookupIssues}} smart value or similar. But the point is that there is only one smart value (variable in this sense). Which ultimately means that it will always contain the the result of the very last Lookup Issues action.
What you could try is something like this:
I never tried it, but could work...
Hi @Shir Avtabi -- Welcome to the Atlassian Community!
It is not possible to have multiple, active Lookup Issues results in a rule at this time.
A work-around is to use the new Lookup Table issue to store the results; the "value" field of a table is an object and may be referenced the same as the lookup. For example...
Kind regards,Bill
Hi @Shir Avtabi
You might try something like this:
The rule is executed in the example above, and returns two variables representing two lists (split shown in yellow) that can be used in later JQL (see below).
The create variable step should look something like this:
You might combine them and use them like this:
TimK.
Hi everyone and @Bill Sheboy ,
I have been a silent admirer of the depth of knowledge that you exhibit on the community pages. This post helped me remove a blocker for a customer solution where I need multiple lookupIssues actions in a rule. Lookup tables! A Fantastic idea! During my quest for workarounds for this limitation of inability to have more than one lookupIssues action, I found another neat solution. I learned that using "set entity properties" you can store the objects (like {{lookupIssues}}) as the value of the property. This gives us another value added feature, since entity properties are accessible globally acrosss projects, so this menas your entity property value(in this case, your loookup issue data) can be used where this property is available!
This way you can effectively have virtually any number of lookup issues in a single rule. Not sure, if any beneficial right away, I also tested that this entity property value object can be stored in a lookup table as well.
I hope this helps our community!
Hi @Aron Gombas _Midori_
When I have tried that method in the past (for lookup issues and web response) the results were stored in the created variable as text, requiring more complicated parsing...and no smart value names unless the results were stored as JSON.
Please see my post for using lookup tables for another approach that preserves the object types.
Hi Bill, thanks so much for your response.
I tried your suggestion but unfortunately I could still only get the latest lookupissue result but nothing from the lookup table.
Maybe you have another suggestion or maybe you know of a feature request that we can vote for?
Thanks a lot!
@Bill Sheboy This is valuable practical insight, thanks!
Interesting...I re-tested that approach before I posted this. Would you please show the complete rule you are using, including details of the table creation and usage in your email?
Sure!
The result I get by mail is the list of the second JQL and the word "and" at the end with nothing after it.
Thanks for looking into it!
Thank you!
Hi @Asim K
Thank you for that additional approach with entity properties.
One possible concern with that approach is automation usage / limits for rules that conditionally perform processing...particularly after the changes to automation packaging.
The Lookup Issues and Create Lookup Table actions do not count as "usage", and so a rule may gather data to decide if usage-impacting actions should happen. But setting an entity property always counts, even if no other usage-impacting actions occur.
It looks like you're new here. Sign in or register to get started.