Automation: How can I check the compare a boolean value of JQL?

Brady May 20, 2022

I'm using automation to perform a "Lookup Issues" action, and in a subsequent JQL Condition using the result of that "Lookup Issues" action to determine if some other action should be performed.

 

The JQL uses a smart value to represent the result of the "Lookup Issues" action. The result is a list, so I'm using the .isEmpty . If the list is empty, I want to proceed. If not, I want to stop the automation gracefully (i.e. without failure).

and the resulting JQL looks like this

{{lookupIssues.isEmpty}} = true

My automation rule keeps failing, and the audit log says:

"

 JQL Condition
No subsequent actions were performed since JQL condition did not pass due to error running JQL:
Invalid JQL: true = true
"
I'll also include picture to hopefully better illustrate
Screen Shot 2022-05-20 at 7.48.15 AM.png

2 answers

2 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.
May 20, 2022

Hi @Brady 

Have you tried an advanced compare condition for this instead of a the JQL one? 

I suspect this is another JQL oddity of both not being an actual SQL and the lookup issues result is not an issue field.

Kind regards,
Bill

Craig Nodwell
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 20, 2022

The way I'm reading it is ... it's not the JQL but the smartvalue doesn't require the "= True" it already resolves to True.  The error message points to this as well.
{{lookupIssues.IsEmpty}} resolves to True or Null not necessary to include the  = True

Like # people like this
Brady May 23, 2022

@Craig Nodwell @Bill Sheboy Just want to let you both know that actually in the end a combination of both of your suggestions ended up working.

I needed to use the Smart Value Conditional Logic that Craig linked, but still I must not have been handling the result of this conditional logic correctly with my JQL. Switching from JQL to advanced compare condition enabled me to handle this correctly. Thank you both so much!

Unfortunately since you were both right, I'm not sure who's answer to accept 😬

Like Bill Sheboy likes this
Brady May 23, 2022

edit: looks like I can accept both. Thanks again for the help!!

1 vote
Answer accepted
Craig Nodwell
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 20, 2022

Hi @Brady this should help.
Smart Values Conditional Logic 

Craig Nodwell
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 20, 2022

trueornull.JPG

Like Brady likes this
Brady May 23, 2022

Hi Craig, Thanks for your suggestion. I truly thought this would be the key, but I'm still having this issue. I've attached the Audit Log. I must be missing something silly here, or maybe this doesn't work in the way I think it does.Screen Shot 2022-05-23 at 11.04.26 AM.png

Craig Nodwell
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 23, 2022

Hi @Brady so I just found this post.
I think your answer is in here.

advcomp.JPG

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
PERMISSIONS LEVEL
Site Admin
TAGS
AUG Leaders

Atlassian Community Events