Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Jira Automation - search script for sending email after 4 days of last work log update

Bill Ewald
Contributor
February 8, 2022

I need to send a reminder email to an Admin if the last work log update was greater than 4 days old.  Having issues with the correct setting for "updated >4d".

My search script:  

project = IT AND issuetype = Sub-task AND status = "In Progress" and updated >4d AND assignee in (identification#) AND issueLinkType = "blocks"

Selected with checkmark = yes (Run a JQL search and execute actions for each issue in the query.)  Selected with checkmark = yes (Only include issues that have changed since the last time this rule executed), (If I change this to unchecked the Query test still = 0 issues found).  Rule has been published.  Query test = 0 issues found.  My last work log update\entry has been 6 days ago.

1 answer

1 accepted

0 votes
Answer accepted
Mark Segall
Community Champion
February 8, 2022

Hi @Bill Ewald - I think you want to use workLogDate instead of Updated in your query

Bill Ewald
Contributor
February 8, 2022

Thank you Mark.  I updated the search script replacing updated with workLogDate and I still receive 0 results.

Mark Segall
Community Champion
February 8, 2022

hmm - What if you try this:

 workLogDate < -4d
Like Bill Ewald likes this
Bill Ewald
Contributor
February 8, 2022

That worked.  I have 1 response to my query.  I will need to wait to see if a test email is received within the 1 hour rule to run.  Why would a double negative time search return results but a single positive time search not?

Mark Segall
Community Champion
February 8, 2022

It's just the way Jira works with relative dates.  Jira interprets your initial query as greater than 4 days from now where the -4d is interpreted as 4 days ago.

Bill Ewald
Contributor
February 8, 2022

Mark, thanks for that clarification!  Working on getting the email to send\receive correctly now.  You have been a big help.  Thanks again.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events