Automation to roll up Target start and Target end from child issues

Steve Teiv
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
January 3, 2025

Hi community!

I am new here and I am struggling with an automation to roll up min target start and max target end dates from child issues to their parent epic.

I followed these pages for reference:

 

My automation looks like this:

automation_rule.GIF

 

And my JSON for setting the field value (eg. target end) is like this:

{ "fields": { "customfield_121": "{{lookupIssues.customfield_121.toDate.max.jiraDate}}" } }

 

 

However the automation ends to an error and audit log gives this error: "

 

 (Error parsing date string: (customfield_121))"

Any ideas on how to proceed or what could be the problem?

Thank you already in advance!

2 answers

1 vote
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.
January 3, 2025

Hi @Steve Teiv -- Welcome to the Atlassian Community!

For Jira Data Center, the Lookup Issues action does not support custom fields yet.  As you want to set another field based upon the values in the child issues of the Epic, the REST API will need to be used.

Please see this post I made in another question for more details: https://community.atlassian.com/t5/Jira-questions/Re-How-to-sum-story-custom-filed-values-to-an-epic/qaq-p/2787339/comment-id/1043853#M1043853

Kind regards,
Bill

0 votes
Tuncay Senturk
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
January 3, 2025

Hi @Steve Teiv 

Is your Target End (customfield_121) a Date field? If it's not, the Automation will fail to parse. 

Null or empty values will also cause the toDate function to fail.

Steve Teiv
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
January 3, 2025

Hi @Tuncay Senturk , no the Target end date is a locked custom field that is created and required by Portfolio for Jira and the type is "Target end".  So does this mean it is not supported?

Steve Teiv
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
January 3, 2025

I also tried changing the JSON:

{
"fields": {
"customfield_121": "{{lookupIssues.customfield_121.toDate.max.("yyyy-MM-dd")}}"
}
}

 

But now it ends in error: " Failed to get value for lookupIssues.customfield_121.toDate.max.("yyyy-MM-dd")"

Tuncay Senturk
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
January 3, 2025

What type is this custom field? You can find the type on the custom fields page. If it is a date field, it should work properly, but you must include a check for null or empty values.

Steve Teiv
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
January 3, 2025

The type column in the custom fields page says "Target end". So it is not a date field. 

 

 

Capture.GIF

Tuncay Senturk
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
January 3, 2025

I am not sure but it might expect the format to be YYYY-MM-DD, YYYY/MM/DD, DD-MM-YYYY

 

 

 

Steve Teiv
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
January 3, 2025

Thank you @Tuncay Senturk , but this doesn't help either. I tired all of those syntaxs. Any other ideas on how to get this work?

Suggest an answer

Log in or Sign up to answer