Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Reference 2 Lookup Issues action list in one rule

Hey,

 

Is it possible to reference 2 different Lookup Issues list in one rule? 

 

I would like to lookup for 2 lists and divide the size of them by each other. 

 

Thanks,

Nofar

1 answer

1 accepted

1 vote
Answer accepted
Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
Jul 28, 2021 • edited

Hi @Nofar Ben Kereth 

No, and...You could store the results such as count (size) in a created variable and use it later once you use Lookup Issues again for the second query.

Best regards,
Bill

That's what I did but it doesn't seem to work. Adding screenshots Screen Shot 2021-07-28 at 17.47.10.pngScreen Shot 2021-07-28 at 17.47.33.png

Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
Jul 28, 2021 • edited

Would you please show what you set as the value for your created variable?  Thanks!

You cannot save the entire {{lookupIssues}} result in a created variable... Although I wonder if it was converted to JSON if that was possible.  Anyways... You can save the count as that is what you wanted for the division:

{{lookupIssues.size|0}}

Note that I added the default value of zero.  That makes it easier to check before trying to divide by zero (or null) later.

And...please note that smart values and functions are case-sensitive, so your division value appears to have the incorrect capitalization for the smart values.

Thanks Bill.

 

Actually I had a problem with the case sensitive smartvalues. 

But I still don't get the right answer. 

I get the value of the second list size and not the answer to the division of the 2. 

 

My variable is simple as {{lookupIssues}} (will add the |0, thanks for the tip :))

Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
Jul 28, 2021

Gotcha; you need to save just the size, not the entire {{lookupIssues}}

Apparently this is what I did, the final number I ger is still the size of the 2nd list. Any idea? 

 

 

Screen Shot 2021-07-28 at 18.46.28.png

Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
Jul 28, 2021

Okay, two things to help/try:

  • At each point where you think you have a value, also use the action to write that to the audit log.  That should confirm if the first lookup issues has any data.
  • Next...and sorry I forgot this: created variables cannot be used as parameters to functions.  So the work-around is to use a math expression and to convert the variable to a number, when editing Epic Progress:
{{#=}}{{lookupIssues.size|0}} / {{IssuesInEpic.asNumber}}{{/}}

You may want to tweak it to get the precision/number of digits you want.  

Thanks! That helped!!

Like Bill Sheboy likes this

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events